Date: Tue, 2 Apr 2019 10:39:42 +0000 From: John F Carr <jfc@mit.edu> To: bob prohaska <fbsd@www.zefox.net> Cc: John F Carr <jfc@mit.edu>, "freebsd-ports@freebsd.org" <freebsd-ports@freebsd.org>, "freebsd-arm@freebsd.org" <freebsd-arm@freebsd.org> Subject: Re: RPI3, error: invalid operand in inline asm: 'rev16 ${0:w}, ${1:w}' Message-ID: <28F4BF7B-4391-4A4B-ABEC-36A154F9FAE2@exchange.mit.edu> In-Reply-To: <20190402015956.GA27268@www.zefox.net> References: <20190330152327.GA11933@www.zefox.net> <236A3D25-0B4D-46DA-95BA-71DA505CC2E0@exchange.mit.edu> <20190402015956.GA27268@www.zefox.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Apr 1, 2019, at 21:59 , bob prohaska <fbsd@www.zefox.net> wrote: >=20 > On Sat, Mar 30, 2019 at 05:50:35PM +0000, John F Carr wrote: >>=20 >>=20 >>> On Mar 30, 2019, at 11:23 , bob prohaska <fbsd@www.zefox.net> wrote: >>>=20 >>> In a recent attempt to compile www/chromium on an RPI3 running r345516 >>> compilation stopped with repeated reports of=20 >>>=20 >>> /usr/include/machine/endian.h:89:19: error: invalid operand in inline a= sm: 'rev16 ${0:w}, ${1:w}' >>>=20 >>> Chromium compiled on the same host a couple of months ago, but the=20 >>> executable failed on a runtime library error. Now attempts to upgrade >>> stop during compilation. Ports are presently at revision 496949. >>>=20 >>> Thanks for reading, and any guidance. >>>=20 >>> bob prohaska >>=20 >> The swap function at that line in sys/arm64/include/endian.h doesn't loo= k right to me. I think it should read >>=20 >> __asm("rev16 %w0, %w1\n" : "=3Dr" (ret) : "r" (w)); >>=20 >> instead of >>=20 >> __asm __volatile("rev16 %w0, %w1\n" : "=3D&r" (ret), "+r" (v)); >>=20 >> Two changes: (1) it doesn't need to be volatile because it has no side e= ffects and (2) the constraints and lack of explicit input operand are wrong= . The other swap functions should have similar changes. >>=20 >=20 > Apologies for being obtuse, but is that suggestive of a problem with the > host system, or a problem with the port? >=20 > Thanks for reading! >=20 > bob prohaska >=20 The problem I mentioned is with the system. I filed a bug: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D236920 If you change the system header /usr/include/machine/endian.h according to the path in that bug report, does chromium compile?=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?28F4BF7B-4391-4A4B-ABEC-36A154F9FAE2>