Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 01 Apr 2019 00:04:10 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-arm@FreeBSD.org
Subject:   [Bug 236920] Bad asm constraints in arm64 byte swap functions
Message-ID:  <bug-236920-7@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D236920

            Bug ID: 236920
           Summary: Bad asm constraints in arm64 byte swap functions
           Product: Base System
           Version: CURRENT
          Hardware: arm64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: arm
          Assignee: freebsd-arm@FreeBSD.org
          Reporter: jfc@mit.edu

Created attachment 203277
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D203277&action=
=3Dedit
Fix inline assembly

The bswap inline functions in sys/arm64/include/endian.h look wrong.

The ARM byte swap instructions are ordinary RISC register to register
instructions and should have "=3Dr" as the constraint on the output operand=
 and
"r" as the constraint on the input operand.

A message to the freebsd-arm list mentioned an error message "invalid opera=
nd
in inline asm" associated with one of the inline assembly statements in
endian.h.  This could have been caused by the strange constraints on the in=
line
assembly.

I've tested that buildworld works with the attached patch.  I have only run=
 a
couple network utilities as a smoke test.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-236920-7>