On Thu, Jan 07, 2021 at 11:20:39AM -0300, Raoni Fassina Firmino wrote:
> On Wed, Nov 18, 2020 at 06:38:22AM -0600, Segher Boessenkool wrote:
> > We can handle the constants issue similarly to what we do for
> > __builtin_fpclassify, too.
> 
> I think that if we must safe-guard for future or unforeseen libc
> implementations doing what __builtin_fpclassify does is the way to go.
> I don't know what is the GCC police here, but IMHO I don't think we
> should add complexity before it is needed in this case.  And looking at
> __builtin_fpclassify, it seems a lot, IIUC this solution needs
> fixinclude to work, seems to me too much add maintenance for something
> that is not needed yet, because SPARC don't have this expands, none has
> for now.

This way the compiler does not need to know the values of the macros
*at all*, that is the whole point!  You simply pass all the standard
values to the builtin as extra arguments.  This may seem inconvenient
to use, but you put the whole thing in a header file anyway, all is
hidden.


Segher

Reply via email to