This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Remove ancient __signbit inlines
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Wilco Dijkstra <Wilco dot Dijkstra at arm dot com>
- Cc: "libc-alpha at sourceware dot org" <libc-alpha at sourceware dot org>, nd <nd at arm dot com>
- Date: Tue, 26 Sep 2017 17:17:00 +0000
- Subject: Re: [PATCH] Remove ancient __signbit inlines
- Authentication-results: sourceware.org; auth=none
- References: <DB6PR0801MB205367C531C71D4E40A0023F837B0@DB6PR0801MB2053.eurprd08.prod.outlook.com>
On Tue, 26 Sep 2017, Wilco Dijkstra wrote:
> Remove __signbit inlines from mathinline.h. Math.h already uses
> the builtin when supported, so additional inlines are only used
> on pre 4.0 GCCs. Similarly remove a few old copysign and fabs
> inlines.
When submitting a patch, please always include a description of how it was
tested.
In this case, I'd expect compilation testing for at least one
configuration using each header that is changed (except ColdFire which
lacks a working glibc build at present), with before-and-after comparison
of stripped binaries and an explanation if the stripped binaries differed
in any way.
The patch is OK if it's passed such testing with unchanged stripped
binaries.
Note that the copysign/fabs inlines removed include ones for __copysign /
__fabs functions which are *not* inlined by the compiler automatically.
The removal is still OK given that those inlines wouldn't have been active
with any compiler version supported for building glibc. But glibc does
have internal __fabs* calls that it would make sense to change to call the
public functions directly so __fabs* inlines are never necessary (and
internal __copysign* calls that it would make sense to change to call
copysign* directly so that the inline in
sysdeps/generic/math_private_calls.h can be removed). (Changes to call
fabsl in ldbl-128ibm would need -fno-builtin-fabsl additions to
sysdeps/powerpc/nofpu/Makefile and both such changes would need powerpc32
soft-float / e500v1 compilation testing to make sure no ldbl-128ibm
functions get called internally by double functions resulting in namespace
issues. Care would also be needed not to get localplt issues for fabsf128
or copysignf128 in configurations using float128, as only
__builtin_fabsf128 / __builtin_copysignf128 get inlined by the compiler.)
--
Joseph S. Myers
joseph@codesourcery.com