[PATCH 2/3] libm: Remove __ieee754_gamma_r variants

Brian Inglis Brian.Inglis@SystematicSw.ab.ca
Thu Sep 3 22:09:34 GMT 2020


On 2020-09-03 15:25, Keith Packard wrote:
> Brian Inglis <Brian.Inglis@SystematicSw.ab.ca> writes:
> 
>>>> Then tell us what you want gamma and gamma_r to do for Cygwin.
>>>
>>> I did: https://sourceware.org/pipermail/newlib/2020/017946.html
> 
> Oops! I appear to have missed that mail.
> 
>> FYI docs/spec:
>> https://sca.uwaterloo.ca/coldfire/gcc-doc/docs/libm_21.html#SEC21
>> http://www.ece.ualberta.ca/~cmpe401/docs/coldfire/libm.pdf#page=20
>> https://ftp.rtems.org/pub/rtems/docs/3.2.0/libm-3.2.0.ps - see p.18
> 
> That's quite helpful actually and says that cygwin's gamma matches
> glibc, which makes the change from 2002 just a bug. Switching gamma back
> to lgamma is quite simple.
> 
> Here's what I did:
> 
>  1. Remove the gamma* function implementations and make them explicit
>     aliases to lgamma*.
> 
>  2. Change the name of the __ieee754_gamma* functions to
>     __ieee754_tgamma* and remove the _ieee754_gamma*_r variants
> 
> I've sent a patch doing this to the list.

I don't think you can "remove the _ieee754_gamma*_r variants" as I believe
Cygwin has to keep these:

$ nm --defined-only --extern-only /bin/cygwin1.dll | fgrep gamma
00000001801a76c0 T __ieee754_gamma_r
00000001801a7f90 T __ieee754_gammaf_r
00000001801a76e0 T __ieee754_lgamma_r
00000001801a7fb0 T __ieee754_lgammaf_r
000000018018a8c0 T __lgammal_r
000000018018ce10 T __tgammal_r
000000018019f690 T gamma
00000001801a0a40 T gamma_r
00000001801a0200 T gammaf
00000001801a0b80 T gammaf_r
000000018019fb00 T lgamma
00000001801a0ae0 T lgamma_r
00000001801a0660 T lgammaf
00000001801a0c20 T lgammaf_r
000000018018ae10 T lgammal
000000018018ae90 T lgammal_r
000000018019fe50 T tgamma
00000001801a0970 T tgammaf
000000018018d290 T tgammal

although I don't have the Windows utilities to check the exports directly.

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in IEC units and prefixes, physical quantities in SI.]

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: OpenPGP digital signature
URL: <https://sourceware.org/pipermail/newlib/attachments/20200903/d907cf86/attachment-0001.sig>


More information about the Newlib mailing list