Message ID | 20180419135901.30035-27-alex.bennee@linaro.org |
---|---|
State | Superseded |
Headers | show |
Series | fix building of tests/tcg | expand |
On 04/19/2018 03:58 AM, Alex Bennée wrote: > +test-arm-iwmmxt: CFLAGS+=-marm -march=iwmmxt -mabi=aapcs > +test-arm-iwmmxt: test-arm-iwmmxt.S This appears to be insufficient. If I begin with armv7l-linux-gnueabihf-gcc, then I get CROSS-BUILD arm guest-tests with armv7l-linux-gnueabihf-gcc cc1: error: iWMMXt and NEON are incompatible r~
Richard Henderson <richard.henderson@linaro.org> writes: > On 04/19/2018 03:58 AM, Alex Bennée wrote: >> +test-arm-iwmmxt: CFLAGS+=-marm -march=iwmmxt -mabi=aapcs >> +test-arm-iwmmxt: test-arm-iwmmxt.S > > This appears to be insufficient. > If I begin with armv7l-linux-gnueabihf-gcc, then I get > > CROSS-BUILD arm guest-tests with armv7l-linux-gnueabihf-gcc > cc1: error: iWMMXt and NEON are incompatible Was this with the docker fall-back? It worked with my local: 07:37:25 [alex@zen:~/l/q/qemu.git] softmmu/demacro-cputlb-rfc + arm-linux-gnueabihf-gcc --version arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. > > > > r~ -- Alex Bennée
On 04/19/2018 10:18 PM, Alex Bennée wrote: > > Richard Henderson <richard.henderson@linaro.org> writes: > >> On 04/19/2018 03:58 AM, Alex Bennée wrote: >>> +test-arm-iwmmxt: CFLAGS+=-marm -march=iwmmxt -mabi=aapcs >>> +test-arm-iwmmxt: test-arm-iwmmxt.S >> >> This appears to be insufficient. >> If I begin with armv7l-linux-gnueabihf-gcc, then I get >> >> CROSS-BUILD arm guest-tests with armv7l-linux-gnueabihf-gcc >> cc1: error: iWMMXt and NEON are incompatible > > Was this with the docker fall-back? No, apparently my docker install is "sudo", and so is unused. > It worked with my local: > > 07:37:25 [alex@zen:~/l/q/qemu.git] softmmu/demacro-cputlb-rfc + arm-linux-gnueabihf-gcc --version > arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9) 5.4.0 20160609 > Copyright (C) 2015 Free Software Foundation, Inc. > This is free software; see the source for copying conditions. There is NO > warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. My arm cross is self-built, with configure options mirroring a native fedora arm gcc: Target: armv7l-linux-gnueabihf Configured with: ../comb/configure --with-sysroot --prefix=/home/rth/work/gcc/run-cross --enable-languages=c,c++,lto --target=armv7l-linux-gnueabihf --with-system-zlib --enable-__cxa_atexit --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-initfini-array --with-cpu=cortex-a15 --with-float=hard --with-fpu=neon-vfpv4 --with-abi=aapcs-linux Thread model: posix gcc version 7.0.0 20161220 (experimental) [master revision f7619de:63fb493:269ead384b0fdd3dd4f7030be44e54e5a19c4e8c] (GCC) r~
diff --git a/tests/tcg/arm/Makefile.target b/tests/tcg/arm/Makefile.target index bc6962ecc6..be9d3fb4a1 100644 --- a/tests/tcg/arm/Makefile.target +++ b/tests/tcg/arm/Makefile.target @@ -8,6 +8,11 @@ ARM_SRC=$(SRC_PATH)/tests/tcg/arm # Set search path for all sources VPATH += $(ARM_SRC) +TESTS += hello-arm test-arm-iwmmxt hello-arm: CFLAGS+=-marm -ffreestanding hello-arm: LDFLAGS+=-nostdlib + +test-arm-iwmmxt: CFLAGS+=-marm -march=iwmmxt -mabi=aapcs +test-arm-iwmmxt: test-arm-iwmmxt.S + $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) diff --git a/tests/tcg/arm/test-arm-iwmmxt.s b/tests/tcg/arm/test-arm-iwmmxt.S similarity index 100% rename from tests/tcg/arm/test-arm-iwmmxt.s rename to tests/tcg/arm/test-arm-iwmmxt.S
We need to rename the source file to a .S so we can do a single-line assemble and link invocation. We also specify the additional CFLAGS for the compile as it's a non-standard ARM binary. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> --- tests/tcg/arm/Makefile.target | 5 +++++ tests/tcg/arm/{test-arm-iwmmxt.s => test-arm-iwmmxt.S} | 0 2 files changed, 5 insertions(+) rename tests/tcg/arm/{test-arm-iwmmxt.s => test-arm-iwmmxt.S} (100%) -- 2.17.0