This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix x86_64 -mfpmath=387 float_t, double_t (bug 20787) [committed]


On Wed, 23 Nov 2016, Florian Weimer wrote:

> On 11/23/2016 06:57 PM, Joseph Myers wrote:
> > Bug 20787 reports that, while float_t and double_t for 32-bit x86
> > properly respect -mfpmath=sse, for x86_64 they fail to reflect
> > -mfpmath=387, which is valid if unusual and results in FLT_EVAL_METHOD
> > being 2.  This patch fixes the definitions to respect
> > __FLT_EVAL_METHOD__ in that case, arranging for the test that the
> > types correspond with FLT_EVAL_METHOD to be run with both -mfpmath=387
> > and -mfpmath=sse.
> 
> If I read the patch correctly, this changes the float_t type for those
> (obscure) configurations.  Doesn't this warrant a NEWS entry?

I've applied this NEWS patch.

diff --git a/NEWS b/NEWS
index 6e256ae..f0e8a1c 100644
--- a/NEWS
+++ b/NEWS
@@ -65,13 +65,20 @@ Version 2.25
   - NaN functions: getpayload, getpayloadf, getpayloadl, setpayload,
     setpayloadf, setpayloadl.
 
+* The functions strfromd, strfromf, and strfroml, from ISO/IEC TS 18661-1:2014,
+  are added to libc.  They convert a floating-point number into string.
+
 * On ColdFire, MicroBlaze, Nios II and SH3, the float_t type is now defined
   to float instead of double.  This does not affect the ABI of any libraries
   that are part of the GNU C Library, but may affect the ABI of other
   libraries that use this type in their interfaces.
 
-* The functions strfromd, strfromf, and strfroml, from ISO/IEC TS 18661-1:2014,
-  are added to libc.  They convert a floating-point number into string.
+* On x86_64, when compiling with -mfpmath=387 or -mfpmath=sse+387, the
+  float_t and double_t types are now defined to long double instead of float
+  and double.  These options are not the default, and this does not affect
+  the ABI of any libraries that are part of the GNU C Library, but it may
+  affect the ABI of other libraries that use this type in their interfaces,
+  if they are compiled or used with those options.
 
 * The <sys/quota.h> header now includes the <linux/quota.h> header.  Support
   for the Linux quota interface which predates kernel version 2.4.22 has

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]