A differential fuzzer for these functions has also been added.
Along the way, a small correction has been done to the normal/subnormal
limits of x86 long double values.
Details
Details
- Reviewers
lntue - Commits
- rG7f7b0dc4e15f: [libc] Add implementations of nextafter[f|l] functions.
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
libc/utils/FPUtil/ManipulationFunctions.h | ||
---|---|---|
162–177 | We can reduce the if-else chain a bit as follows: if (from != T(0.0)) { if ((from < to) == (from > T(0.0)) { ++intVal; } else { --intVal; } } else { intVal = (to.bitsAsUInt() & signMask) + UIntType(1); } |
We can reduce the if-else chain a bit as follows: