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: Ping Re: Make strtod respect the rounding mode (bug 14518)


On Wed, 12 Sep 2012, Richard Henderson wrote:

> On 09/12/2012 08:31 AM, Joseph S. Myers wrote:
> > The idea is to have the same set of *names* present in the code 
> > everywhere, so that code using these values doesn't need to be conditioned 
> > on which are available on a particular architecture.  This includes 
> > setting the mode to round_tonearest in cases where there is no rounding 
> > mode support for an architecture and so no FE_* macros are defined at all.
> 
> My suggestion then is that those few targets that have no rounding mode
> support be required to define the FE_* macros in get-rounding-mode.h.
> Given that this header is totally private to the library, they can make
> up any values they choose to let the generic parts compile.

Do you then suggest that sysdeps/generic/get-rounding-mode.h should 
translate _FPU_RC_* into FE_* (which might or might not be a no-op 
translation)?  It could define FE_* in the case that none are defined; it 
would be cases defining a nonempty proper subset (such as SH and Tile and 
am33) that would need their own get-rounding-mode.h where they didn't 
previously.  And would you also eliminate the rounding_mode_t type (since 
FE_* are just ints)?

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