diff options
author | Reid Spencer <rspencer@reidspencer.com> | 2006-11-25 08:38:44 +0000 |
---|---|---|
committer | Reid Spencer <rspencer@reidspencer.com> | 2006-11-25 08:38:44 +0000 |
commit | aa5c220665ede7ac39d1c06e0ad88583ed96ea4d (patch) | |
tree | 257feab2a7f9b5a8b1dd4d48593b035d7f6aa8da /llvm/lib/Support/FileUtilities.cpp | |
parent | 6968c497de879c974ccbc34b372ab2a781ab5a55 (diff) | |
download | bcm5719-llvm-aa5c220665ede7ac39d1c06e0ad88583ed96ea4d.tar.gz bcm5719-llvm-aa5c220665ede7ac39d1c06e0ad88583ed96ea4d.zip |
Make the absolute/relative tolerance information easier to read/understand.
llvm-svn: 31908
Diffstat (limited to 'llvm/lib/Support/FileUtilities.cpp')
-rw-r--r-- | llvm/lib/Support/FileUtilities.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/Support/FileUtilities.cpp b/llvm/lib/Support/FileUtilities.cpp index ea7822a2c4b..adee22d3191 100644 --- a/llvm/lib/Support/FileUtilities.cpp +++ b/llvm/lib/Support/FileUtilities.cpp @@ -106,8 +106,9 @@ static bool CompareNumbers(char *&F1P, char *&F2P, char *F1End, char *F2End, Diff = 0; // Both zero. if (Diff > RelTolerance) { if (ErrorMsg) { - *ErrorMsg = "Compared: " + ftostr(V1) + " and " + ftostr(V2) + - ": diff = " + ftostr(Diff) + "\n"; + *ErrorMsg = "Compared: " + ftostr(V1) + " and " + ftostr(V2) + "\n"; + *ErrorMsg += "abs. diff = " + ftostr(std::abs(V1-V2)) + + " rel.diff = " + ftostr(Diff) + "\n"; *ErrorMsg += "Out of tolerance: rel/abs: " + ftostr(RelTolerance) + "/" + ftostr(AbsTolerance); } |