Hi all, I'd like to submit the following patch to better specify the meaning of the 'arm_softfloat' effective target.
As I've recently discovered we can have cases where '-mfloat-abi=hard' is used and the compiler correctly defines '__SOFTFP__'. Effectively 'arm_softfloat' is checking if the target requires floating point emulation but not what ABI is used, so I think would be nice to specify that in the documentation. Okay for trunk? Thanks Andrea
>From 67e74689e4332d33c3f27119dc21a7722bb6125b Mon Sep 17 00:00:00 2001 From: Andrea Corallo <andrea.cora...@arm.com> Date: Tue, 1 Dec 2020 11:21:33 +0100 Subject: [PATCH] arm: Improve documentation for effective target 'arm_softfloat' gcc/ChangeLog 2020-12-01 Andrea Corallo <andrea.cora...@arm.com> * doc/sourcebuild.texi (arm_softfloat): Improve documentation. gcc/testsuite/ChangeLog 2020-12-01 Andrea Corallo <andrea.cora...@arm.com> * lib/target-supports.exp (check_effective_target_arm_softfloat): Improve documentation. --- gcc/doc/sourcebuild.texi | 3 +-- gcc/testsuite/lib/target-supports.exp | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/gcc/doc/sourcebuild.texi b/gcc/doc/sourcebuild.texi index 852eaa2e676..72b83748318 100644 --- a/gcc/doc/sourcebuild.texi +++ b/gcc/doc/sourcebuild.texi @@ -1799,8 +1799,7 @@ variant of the ABI for the ARM Architecture (as selected with @code{-mfloat-abi=hard}). @item arm_softfloat -ARM target uses the soft-float ABI with no floating-point instructions -used whatsoever (as selected with @code{-mfloat-abi=soft}). +ARM target uses emulated floating point operations. @item arm_hard_vfp_ok ARM target supports @code{-mfpu=vfp -mfloat-abi=hard}. diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index ff6bc5f4b92..24ff9fa0476 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -5658,8 +5658,8 @@ proc check_effective_target_arm_hf_eabi { } { }] } -# Return 1 if this is an ARM target that uses the soft float ABI -# with no floating-point instructions at all (e.g. -mfloat-abi=soft). +# Return 1 if this is an ARM target uses emulated floating point +# operations. proc check_effective_target_arm_softfloat { } { return [check_no_compiler_messages arm_softfloat object { -- 2.20.1