[libc-commits] [PATCH] D118157: [libc] Improve hypotf performance with different algorithm correctly rounded to all rounding modes.
Tue Ly via Phabricator via libc-commits
libc-commits at lists.llvm.org
Wed Jan 26 07:53:36 PST 2022
lntue added a comment.
In D118157#3272333 <https://reviews.llvm.org/D118157#3272333>, @zimmermann6 wrote:
> I get some errors for rounding to nearest:
>
> Difference for 0x1.faf49ep+25,0x1.480002p+23
> llvm_hypot: 0x1.00c5bp+26
> as_hypot: 0x1.00c5b2p+26
> pz_hypot: 0x1.00c5b2p+26
Thanks Paul for finding the error! For this example, the sum square is actually exact, but the rounding errors still need to be updated in order to avoid double rounding errors. By removing the check (err != 0) in line 36, I got it back correctly.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D118157/new/
https://reviews.llvm.org/D118157
More information about the libc-commits
mailing list