[llvm-bugs] [Bug 50818] New: Some tests compare hash values as if they were floating point
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Jun 23 09:28:14 PDT 2021
https://bugs.llvm.org/show_bug.cgi?id=50818
Bug ID: 50818
Summary: Some tests compare hash values as if they were
floating point
Product: Test Suite
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Nightly Tester
Assignee: unassignedbugs at nondot.org
Reporter: andrew.kaylor at intel.com
CC: llvm-bugs at lists.llvm.org
Some tests in the test suite (I'm not sure how many) are hashing the test
output but then using fpcmp to compare the hashed result to the expected hash.
For example, I ran the test suite with "-ffp-contract=on" as an extra compile
option (before a recent change which disabled fp contraction in a number of
tests) and observed the following with the Microbenchmarks/ImageProcessing/Blur
test:
Expected hash value: 7f4246596bcfbb5e6e44cd21ddfeaf07
Actual hash value: 6098466d4eeaf5ccd1871870206176c9
Test error message:
fpcmp-target: Compared: 7.000000e+00 and 6.098466e+10
abs. diff = 6.098466e+10 rel.diff = 1.000000e+00
Out of tolerance: rel/abs: 0.000000e+00/0.000000e+00
The error message results from the test calling fpcmp-target, which looks for
the first thing that seems to be a number and converts it to a floating point
value. So, in this case it was comparing “7” to “6098466”. If the first
character of either hash value is non-numeric, it reports a “not a numeric
difference” error.
The comparison works (for the wrong reasons) if the test produces the exact
output that is expected, but there is no way to allow any floating point
tolerance and the error message is incorrect.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210623/23acac61/attachment.html>
More information about the llvm-bugs
mailing list