[flang-commits] [PATCH] D128261: [Fortran] Relax tolerance for FCVS tests
Andrzej Warzynski via Phabricator via flang-commits
flang-commits at lists.llvm.org
Thu Jun 23 05:52:09 PDT 2022
awarzynski added a comment.
In D128261#3601206 <https://reviews.llvm.org/D128261#3601206>, @rovka wrote:
> Thanks for the explanation! I have updated the patch description with all the information. fpcmp does treat everything as double precision.
This makes sense to me. Indeed, fpcmp <https://github.com/llvm/llvm-test-suite/blob/main/tools/fpcmp.c> uses `double` for all floating point values.
> relaxes the tolerance for the FCVS tests to permit both values, since they are both close enough (the absolute difference is small)
Yeah, the absolute difference is negligible. Note that `FP_TOLERANCE` is used as the relative tolerance when passed to `fpcmp` (see `fpcmp` invocation here <https://github.com/llvm/llvm-test-suite/blob/main/cmake/modules/SingleMultiSource.cmake#L126> and the help text <https://github.com/llvm/llvm-test-suite/blob/main/tools/fpcmp.c#L373-L376> from `fpcmp` documents its arguments). I think that `1e-7` as relative tolerance gives enough precision here. `1e-11` was too aggressive IMO - perhaps that was meant as absolute tolerance (which, btw, I don't see being specified)?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D128261/new/
https://reviews.llvm.org/D128261
More information about the flang-commits
mailing list