This is an archive of the discontinued LLVM Phabricator instance.

[libc] Return correct values for hypot when overflowed.
ClosedPublic

Authored by lntue on Sep 6 2022, 11:44 AM.

Details

Summary

Hypot incorrectly returns +Inf when overflowed with FE_DOWNWARD and
FE_TOWARDZERO rounding modes.

Diff Detail

Event Timeline

lntue created this revision.Sep 6 2022, 11:44 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptSep 6 2022, 11:44 AM
lntue requested review of this revision.Sep 6 2022, 11:44 AM
sivachandra accepted this revision.Sep 6 2022, 3:46 PM
This revision is now accepted and ready to land.Sep 6 2022, 3:46 PM
zimmermann6 accepted this revision.Sep 7 2022, 3:19 AM

ok for me. I have added more checks near the underflow and overflow boundaries in CORE-MATH check.sh, and it passes all tests.

This revision was automatically updated to reflect the committed changes.