diff options
author | Joseph Myers <josmyers@redhat.com> | 2024-08-27 12:41:02 +0000 |
---|---|---|
committer | Joseph Myers <josmyers@redhat.com> | 2024-08-27 12:41:02 +0000 |
commit | 457622c2fa8f9f7435822d5287a437bc8be8090d (patch) | |
tree | 01827cadfdefef2117696ad3f82ff0bdd2a77c03 /sysdeps/unix/sysv/linux/nios2/libnsl.abilist | |
parent | d73ed2601b7c3c93c3529149a3d7f7b6177900a8 (diff) | |
download | glibc-457622c2fa8f9f7435822d5287a437bc8be8090d.tar.gz glibc-457622c2fa8f9f7435822d5287a437bc8be8090d.tar.xz glibc-457622c2fa8f9f7435822d5287a437bc8be8090d.zip |
Fix strtod subnormal rounding (bug 30220)
As reported in bug 30220, the implementation of strtod-family functions has a bug in the following case: the input string would, with infinite exponent range, take one more bit to represent than is available in the normal precision of the return type; the value represented is in the subnormal range; and there are no nonzero bits in the value, below those that can be represented in subnormal precision, other than the least significant bit and possibly the 0.5ulp bit. In this case, round_and_return ends up discarding the least significant bit. Fix by saving that bit to merge into more_bits (it can't be merged in at the time it's computed, because more_bits mustn't include this bit in the case of after-rounding tininess detection checking if the result is still subnormal when rounded to normal precision, so merging this bit into more_bits needs to take place after that check). Tested for x86_64.
Diffstat (limited to 'sysdeps/unix/sysv/linux/nios2/libnsl.abilist')
0 files changed, 0 insertions, 0 deletions