diff mbox series

arm: Improve documentation for effective target 'arm_softfloat'

Message ID gkr7dq1tz16.fsf@arm.com
State New
Headers show
Series arm: Improve documentation for effective target 'arm_softfloat' | expand

Commit Message

Andrea Corallo Dec. 1, 2020, 1:51 p.m. UTC
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.corallo@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.corallo@arm.com>

	* doc/sourcebuild.texi (arm_softfloat): Improve documentation.

gcc/testsuite/ChangeLog

2020-12-01  Andrea Corallo  <andrea.corallo@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(-)

Comments

Andrea Corallo Dec. 8, 2020, 11:10 a.m. UTC | #1
Andrea Corallo via Gcc-patches <gcc-patches@gcc.gnu.org> writes:

> 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
>   

Ping
Kyrylo Tkachov Dec. 11, 2020, 11:19 a.m. UTC | #2
> -----Original Message-----
> From: Andrea Corallo <Andrea.Corallo@arm.com>
> Sent: 01 December 2020 13:52
> To: gcc-patches@gcc.gnu.org
> Cc: Kyrylo Tkachov <Kyrylo.Tkachov@arm.com>; Richard Earnshaw
> <Richard.Earnshaw@arm.com>; nd <nd@arm.com>
> Subject: [PATCH] arm: Improve documentation for effective target
> 'arm_softfloat'
> 
> 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?

Ok.
Thanks,
Kyrill

> 
> Thanks
> 
>   Andrea
>
Andrea Corallo Dec. 11, 2020, 2:26 p.m. UTC | #3
Kyrylo Tkachov <Kyrylo.Tkachov@arm.com> writes:

>> -----Original Message-----
>> From: Andrea Corallo <Andrea.Corallo@arm.com>
>> Sent: 01 December 2020 13:52
>> To: gcc-patches@gcc.gnu.org
>> Cc: Kyrylo Tkachov <Kyrylo.Tkachov@arm.com>; Richard Earnshaw
>> <Richard.Earnshaw@arm.com>; nd <nd@arm.com>
>> Subject: [PATCH] arm: Improve documentation for effective target
>> 'arm_softfloat'
>> 
>> 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?
>
> Ok.
> Thanks,
> Kyrill

And also this is into trunk as 33314b11ca2.

Thanks!

  Andrea
diff mbox series

Patch

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 {