> Le 19 avr. 2016 à 15:21, Yvan Roux <yvan.r...@linaro.org> a écrit :
> 
> On 19 April 2016 at 14:47, Laurent Thévenoux
> <laurent.theven...@ens-lyon.fr <mailto:laurent.theven...@ens-lyon.fr>> wrote:
>> Hi Yvan,
>> 
>> Le 19 avr. 2016 à 13:46, Yvan Roux <yvan.r...@linaro.org> a écrit :
>> 
>> Hi Laurent,
>> 
>> On 19 April 2016 at 11:00, Laurent Thévenoux
>> <laurent.theven...@ens-lyon.fr> wrote:
>> 
>> Dear Devs,
>> 
>> I get the following error when I use gcc 4.9.4 with the -mcpu flag set with
>> a certain configuration of ‘feature/nofeature’, i.e.:
>> -mcpu=cortex-a57+fp+simd+nocrypto+nocrc will fail, but
>> -mcpu=cortex-a57+fp+nocrypto+simd+nocrc won’t, for example.
>> 
>> Here the error I get with the former -mcpu flag:
>> 
>> Assembler messages:
>> Error: unknown architectural extension `n'
>> Error: unrecognized option -mcpu=cortex-a57+fp+simd+n
>> 
>> 
>> Minimal test case: $gcc -march=armv8-a+fp+simd+nocrc+nocrypto
>> -mcpu=cortex-a57+fp+simd+nocrypto+nocrc -mtune=cortex-a57 helloworld.c.
>> 
>> According to the gcc documentation
>> <https://gcc.gnu.org/onlinedocs/gcc-4.9.3/gcc/AArch64-Options.html#AArch64-Options>
>> the order seems to be irrelevant. I obtained the error with the linaro-gcc
>> 4.9.4 binary release, as well as a personal built from linaro sources
>> package. It also fails with gcc 4.9.2 on the 3.18.0-linaro-hikey debian
>> distribution.
>> 
>> I also tried with (linaro) gcc 4.8.5, 5.1.1, 5.2.1, and 5.3.1 versions, and
>> it works well.
>> 
>> 
>> On which version of GCC 4.9.4 do you see that issue ? I can't
>> reproduce with our latest 4.9.4 release (4.9-2016.02) which is
>> available here:
>> 
>> https://releases.linaro.org/components/toolchain/binaries/4.9-2016.02/aarch64-linux-gnu/
>> 
>> 
>> I think I have the latest one, -v gives me: gcc version 4.9.4 20151028
>> (prerelease) (Linaro GCC 4.9-2016.02).
>> 
>> Moreover, I downloaded the version from your link, and I reproduce the issue
>> with :
>> 
>> $
>> ./gcc-linaro-4.9-2016.02-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-gcc
>> -march=armv8-a+fp+simd+nocrc+nocrypto
>> -mcpu=cortex-a57+fp+simd+nocrypto+nocrc -mtune=cortex-a57 helloworld.c
>> Assembler messages:
>> Error: unknown architectural extension `n'
>> Error: unrecognized option -mcpu=cortex-a57+fp+simd+n
> 
> Ah, indeed sorry I assumed it was a compiler issue and stop the
> compilation after cc1 (option -S), and the error messages are given by
> the assembler, which comes from binutils version 2.24 in our 4.9.4
> binary release, whereas it is binutils version 2.25 in GCC 5 ones.
> 
> The commit which fixed this issue in 2.25 is this one:
> 
> https://sourceware.org/ml/binutils/2014-11/msg00135.html 
> <https://sourceware.org/ml/binutils/2014-11/msg00135.html>
Thank you very much! 

Do you know in which version of binutils it was corrected? Because, I built gcc 
4.9.4 with binutils 2.25.1, and I still reproduce the issue (see below, take a 
look at the ‘as’ call: the -mcpu flag is truncated). With gcc 4.8, 5.1, 5.2 and 
5.3 (all with the same binutils), the issue doesn’t appear. 

—

$ ../compilers/bin/gcc-aarch64-linux-gnu-4.9.4-original 
-march=armv8-a+fp+simd+nocrc+nocrypto -mcpu=cortex-a57+fp+simd+nocrypto+nocrc 
-mtune=cortex-a57 ../compilers/tests/test-sources/hw.c -v
Using built-in specs.
COLLECT_GCC=../compilers/bin/gcc-aarch64-linux-gnu-4.9.4-original
COLLECT_LTO_WRAPPER=/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/libexec/gcc/aarch64-linux-gnu/4.9.4/lto-wrapper
Target: aarch64-linux-gnu
Configured with: 
/home/ltheveno/compilers/gcc/linaro/srcs-tmp/gcc-linaro-4.9-2016.02/configure 
--prefix=/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu
 --target=aarch64-linux-gnu --program-suffix= --program-prefix= 
--enable-languages=c,c++,fortran --disable-multilib
Thread model: posix
gcc version 4.9.4 20151028 (prerelease) (Linaro GCC 4.9-2016.02) 
COLLECT_GCC_OPTIONS='-march=armv8-a+fp+simd+nocrc+nocrypto' 
'-mcpu=cortex-a57+fp+simd+nocrypto+nocrc' '-mtune=cortex-a57' '-v' 
'-mlittle-endian' '-mabi=lp64'
 
/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/libexec/gcc/aarch64-linux-gnu/4.9.4/cc1
 -quiet -v ../compilers/tests/test-sources/hw.c -quiet -dumpbase hw.c 
-march=armv8-a+fp+simd+nocrc+nocrypto -mcpu=cortex-a57+fp+simd+nocrypto+nocrc 
-mtune=cortex-a57 -mlittle-endian -mabi=lp64 -auxbase hw -version -o 
/tmp/cczMgau9.s
GNU C (Linaro GCC 4.9-2016.02) version 4.9.4 20151028 (prerelease) 
(aarch64-linux-gnu)
        compiled by GNU C version 4.9.2, GMP version 6.1.0, MPFR version 3.1.3, 
MPC version 1.0.3
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
ignoring nonexistent directory 
"/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/4.9.4/../../../../aarch64-linux-gnu/sys-include"
#include "..." search starts here:
#include <...> search starts here:
 
/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/4.9.4/include
 
/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/4.9.4/include-fixed
 
/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/4.9.4/../../../../aarch64-linux-gnu/include
End of search list.
GNU C (Linaro GCC 4.9-2016.02) version 4.9.4 20151028 (prerelease) 
(aarch64-linux-gnu)
        compiled by GNU C version 4.9.2, GMP version 6.1.0, MPFR version 3.1.3, 
MPC version 1.0.3
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: d907d11377ac36f51e1d0916e7c06893
COLLECT_GCC_OPTIONS='-march=armv8-a+fp+simd+nocrc+nocrypto' 
'-mcpu=cortex-a57+fp+simd+nocrypto+nocrc' '-mtune=cortex-a57' '-v' 
'-mlittle-endian' '-mabi=lp64'
 
/home/ltheveno/compilers/gcc/linaro/builds/original-gcc-linaro-4.9-2016.02-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/4.9.4/../../../../aarch64-linux-gnu/bin/as
 -v -EL -march=armv8-a+fp+simd+nocrc+nocrypto -mcpu=cortex-a57+fp+simd+n 
-mabi=lp64 -o /tmp/cc4LuQND.o /tmp/cczMgau9.s
GNU assembler version 2.25.1 (aarch64-linux-gnu) using BFD version (GNU 
Binutils) 2.25.1
Assembler messages:
Error: unknown architectural extension `n'
Error: unrecognized option -mcpu=cortex-a57+fp+simd+n

_______________________________________________
linaro-dev mailing list
linaro-dev@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/linaro-dev

Reply via email to