[PATCH][AArch64] Add inlines for signbit (v2)
Wilco Dijkstra
wdijkstr@arm.com
Fri May 22 17:16:00 GMT 2015
> Joseph wrote:
> On Fri, 22 May 2015, Wilco Dijkstra wrote:
>
> > OK, I tried that and it works fine without having to change all the targets if
> > I define __signbit at the end of math.h.
>
> If a target's inline __signbit definitions are completely obsolete with
> this change, they should be removed as part of it. That means at least
> removing sysdeps/tile/bits/mathinline.h, since it only uses
> __builtin_signbit* and GCC versions before 4.0 don't support Tile.
> (ColdFire bits/mathinline.h confuses things by not having a GCC version
> conditional and so potentially using the builtins with GCC versions before
> 4.0 that had ColdFire support. But since 3.4 didn't support
> __builtin_signbit, I think that can be considered a clear bug and so the
> patch should also remove sysdeps/m68k/coldfire/fpu/bits/mathinline.h as
> obsoleted by the generic changes.)
OK, I'll update the patch to remove those.
> > +# if __GNUC_PREREQ (4,0)
> > +# undef __signbitl
>
> Why the #undef? I don't see any headers with macro definitions of
> __signbitl that need to be removed in math.h.
Unless nldbl support is dead we need it as sysdeps/ldbl-opt/nldbl-signbit.c does:
#define __signbitl __signbitl_XXX
#include "nldbl-compat.h"
nldbl-compat.h includes math/math.h, which would define __signbitl again.
I couldn't force nldbl to build but replacing sysdeps/ieee754/ldbl-128/s_signbitl.c
with nldlb-signbit.c confirmed the #undef fixes the issue.
Wilco
More information about the Libc-alpha
mailing list