aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
diff options
context:
space:
mode:
authorSiva Chandra Reddy <sivachandra@google.com>2020-04-30 10:02:09 -0700
committerSiva Chandra Reddy <sivachandra@google.com>2020-05-06 10:47:23 -0700
commita7e11496996269fc589322da7bedbe4b1adcb13f (patch)
tree10c24110de7532019f7b2e581252ce772c1ed209 /llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
parente382b3770ed721d63c0c039ff1ceee1b67802b05 (diff)
downloadllvm-a7e11496996269fc589322da7bedbe4b1adcb13f.zip
llvm-a7e11496996269fc589322da7bedbe4b1adcb13f.tar.gz
llvm-a7e11496996269fc589322da7bedbe4b1adcb13f.tar.bz2
[libc] Fix how math results are compared with MPFR results.
Summary: Math results are compared with MPFR results by checking if they are within a tolerance level of the MPFR result. The tolerance level is set using additional bits of precision of the fractional part of a floating point value. Hence, the actual value of the tolerance depends on not only the additional bits, but also on the exponent part of the floating point number. Previously, the exponent part was not considered in evaluating the tolerance value. While it was OK for small values less than 1 (hence sinf, cosf, sincosf tests were OK), it breaks for large values which functions like exp and friends produce. This change uses the exponent value also to evaluate the tolerance value. LLVM libc produced results can now be compared with MPFR produced results for large values also. Reviewers: abrachet Differential Revision: https://reviews.llvm.org/D79278
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp')
0 files changed, 0 insertions, 0 deletions