Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-24 Thread Joseph Myers
On Thu, 24 Jan 2019, Christophe Lyon wrote: > On Thu, 24 Jan 2019 at 15:31, Joseph Myers wrote: > > > > On Thu, 24 Jan 2019, Christophe Lyon wrote: > > > > > The attached small patch adds > > > /* { dg-require-effective-target fenv_exceptions } */ > > > to them. > > > > It should be a *new* effec

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-24 Thread Dominique d'Humières
The test gcc.dg/torture/fp-int-convert-timode-3.c fails on darwin: the results are -0x1p+127 -0x1p+127 TIA Dominique

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-24 Thread Christophe Lyon
On Thu, 24 Jan 2019 at 15:31, Joseph Myers wrote: > > On Thu, 24 Jan 2019, Christophe Lyon wrote: > > > The attached small patch adds > > /* { dg-require-effective-target fenv_exceptions } */ > > to them. > > It should be a *new* effective-target, because these tests are nothing to > do with excep

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-24 Thread Joseph Myers
On Thu, 24 Jan 2019, Christophe Lyon wrote: > The attached small patch adds > /* { dg-require-effective-target fenv_exceptions } */ > to them. It should be a *new* effective-target, because these tests are nothing to do with exceptions; they're about rounding modes (but actually you only need a

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-24 Thread Christophe Lyon
On Wed, 23 Jan 2019 at 22:14, H.J. Lu wrote: > > On Wed, Jan 23, 2019 at 12:50 PM Joseph Myers wrote: > > > > On Wed, 23 Jan 2019, H.J. Lu wrote: > > > > > + fesetround (FE_DOWNWARD); > > > + float fs = s128; > > > + if (fs != -0x1p+127) > > > +abort (); > > > + double ds = s128; > > > +

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-23 Thread H.J. Lu
On Wed, Jan 23, 2019 at 12:50 PM Joseph Myers wrote: > > On Wed, 23 Jan 2019, H.J. Lu wrote: > > > + fesetround (FE_DOWNWARD); > > + float fs = s128; > > + if (fs != -0x1p+127) > > +abort (); > > + double ds = s128; > > + if (ds != -0x1p+127) > > +abort (); > > This definitely needs #

Re: [PATCH] libgcc2.c: Correct DI/TI -> SF/DF conversions

2019-01-23 Thread Joseph Myers
On Wed, 23 Jan 2019, H.J. Lu wrote: > + fesetround (FE_DOWNWARD); > + float fs = s128; > + if (fs != -0x1p+127) > +abort (); > + double ds = s128; > + if (ds != -0x1p+127) > +abort (); This definitely needs #ifdef FE_DOWNWARD; even just limited to glibc configurations, there are sof