aboutsummaryrefslogtreecommitdiff
path: root/gcc/combine.c
diff options
context:
space:
mode:
authorRichard Earnshaw <rearnsha@arm.com>2017-12-08 10:55:01 +0000
committerRichard Earnshaw <rearnsha@gcc.gnu.org>2017-12-08 10:55:01 +0000
commit940269b679a628dbb1f3891b7e57b80db6743615 (patch)
treef8c721ce19f8a0a5fe66c2dba6f051b5a4b28054 /gcc/combine.c
parent4a53066d0e9be7ef045dabbe497eeeca0ce2c7fc (diff)
downloadgcc-940269b679a628dbb1f3891b7e57b80db6743615.zip
gcc-940269b679a628dbb1f3891b7e57b80db6743615.tar.gz
gcc-940269b679a628dbb1f3891b7e57b80db6743615.tar.bz2
[arm] Generate a -mfpu= option for passing to the assembler
When gcc runs with the new -mfpu=auto option (either explicitly or when that's the default behaviour) then this option is not passed through to the assembler as we cannot rely on the assembler understanding it (currently it doesn't understand it at all, but in future that might change). That means that the assembler falls back to its builtin default, which may not correspond to what the user expected based on the command-line options they passed. Normally that wouldn't matter because assembler files generated by the compiler will contain explicit directives that set the FPU type directly and override any internal defaults; but when the compiler driver is used to invoke the assembler directly (because the source file ends in .s or .S) then this might cause a problem if that assumes the FPU matches the compiler. To address this, this patch makes the driver construct a -mfpu= option for the assembler in the same way as the compiler generates an internal .fpu directive. As mentioned, this makes no difference if the assembler file explicitly overrides the command line options, but helps in the case where this is implicit. * config/arm/arm.h (arm_asm_auto_mfpu): Declare. (ASM_CPU_SPEC_FUNCTIONS): Add new rule asm_auto_mfpu. (ASM_CPU_SPEC): Use it if -mfpu is set to auto. * common/config/arm/arm-common.c (arm_asm_auto_mfpu): New function. -- This line, and those below, will be ignored-- M gcc/ChangeLog M gcc/common/config/arm/arm-common.c M gcc/config/arm/arm.h From-SVN: r255502
Diffstat (limited to 'gcc/combine.c')
0 files changed, 0 insertions, 0 deletions