diff options
author | Joseph Myers <joseph@codesourcery.com> | 2017-12-19 02:02:26 +0000 |
---|---|---|
committer | Joseph Myers <joseph@codesourcery.com> | 2017-12-19 02:02:26 +0000 |
commit | 664251859260d3cca6a477fb08c3b9f2b78a4fd9 (patch) | |
tree | 6862a783277d1253893d35f3afba0b0c796c9f49 /scripts | |
parent | 8e52f573a1e0c2c39968051bcf683805540deb03 (diff) | |
download | glibc-664251859260d3cca6a477fb08c3b9f2b78a4fd9.tar glibc-664251859260d3cca6a477fb08c3b9f2b78a4fd9.tar.gz glibc-664251859260d3cca6a477fb08c3b9f2b78a4fd9.tar.bz2 glibc-664251859260d3cca6a477fb08c3b9f2b78a4fd9.zip |
Fix m68k bits/mathinline.h attributes (bug 22631).
m68k bits/mathinline.h declares various functions with const
attributes. These are inappropriate for functions that have results
depending on the rounding mode; the machine-independent
bits/mathcalls.h only uses const attributes for a very few functions
with no rounding mode dependence, and the m68k header should do
likewise. GCC uses pure for such functions with -frounding-math,
resulting in GCC mainline warning for conflicts with between the
header and the built-in attributes and glibc failing to build for m68k
with GCC mainline.
This patch fixes the attributes to avoid using const except when
bits/mathcalls.h does so. (There are a few functions where maybe
bits/mathcalls.h could do so but doesn't, but keeping the headers in
sync in this regard seems to be the safe approach.)
Tested compilation with build-many-glibcs.py with GCC mainline.
[BZ #22631]
* sysdeps/m68k/m680x0/fpu/bits/mathinline.h (__m81_defun): Add
argument for attrubutes. All callers changed.
(__inline_mathop1): Likewise. All callers changed.
(__inline_mathop): Likewise. All callers changed.
[__USE_MISC] (scalbn): Use __inline_forward instead of
__inline_forward_c.
[__USE_ISOC99] (scalbln): Likewise.
[__USE_ISOC99] (nearbyint): Likewise.
[__USE_ISOC99] (lrint): Likewise.
[__USE_MISC] (scalbnf): Likewise.
[__USE_ISOC99] (scalblnf): Likewise.
[__USE_ISOC99] (nearbyintf): Likewise.
[__USE_ISOC99] (lrintf): Likewise.
[__USE_MISC] (scalbnl): Likewise.
[__USE_ISOC99] (scalblnl): Likewise.
[__USE_ISOC99] (nearbyintl): Likewise.
[__USE_ISOC99] (lrintl): Likewise.
* sysdeps/m68k/m680x0/fpu/mathimpl.h: All callers of
__inline_mathop and __m81_defun changed.
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions