[flang-commits] [PATCH] D128262: [Fortran] Avoid digits in character constant

Diana Picus via Phabricator via flang-commits flang-commits at lists.llvm.org
Fri Jul 1 02:20:01 PDT 2022


rovka added a comment.

In D128262#3623448 <https://reviews.llvm.org/D128262#3623448>, @Meinersbur wrote:

> In D128262#3605337 <https://reviews.llvm.org/D128262#3605337>, @awarzynski wrote:
>
>> I've scanned llvm-test-suite and I don't see any obvious way to use any other DIFFPROGR <https://github.com/llvm/llvm-test-suite/blob/25c31a4e8b54b5e2d4e03b21aa6631fdb248dc6e/cmake/modules/SingleMultiSource.cmake#L124>. So it sounds like we can only use `fpcmp` for now and this tool shouldn't  be comparing strings, should it? Perhaps switching from SingleSource <https://github.com/llvm/llvm-test-suite/blob/25c31a4e8b54b5e2d4e03b21aa6631fdb248dc6e/cmake/modules/SingleMultiSource.cmake#L1> CMake logic in the test suite to e.g. TestFile <https://github.com/llvm/llvm-test-suite/blob/25c31a4e8b54b5e2d4e03b21aa6631fdb248dc6e/cmake/modules/TestFile.cmake> would help, but that's IMO outside the scope of this patch.
>
> SingleMultiSource is a skeleton for the simplest of test cases (program consists of single source file, stdout/err is compared to reference in file)
> I've integrated other validators than fpmcp (https://github.com/llvm/llvm-test-suite/blob/8e4703af93b04d72e225215e67a89973e84e59fd/External/SPEC/SpecCPU2017.cmake#L258) using `llvm_test_verify`. `fpcmp` has its issues as well in that is ALWAYS (even with 0 tolerance) parses anything that looks like a floating-point number (as you noticed). This has been brought up before but nobody has changed it yet. I think that would be the cleaner (and overdue) solution.
>
> @rovka 
> Since I changed `fpcmp` before (basically I rewrote the entire comparison algorithm once), I could help with that.

Ok, feel free to have a stab at it :) I'm going to be on vacation until the 20th of July, so I'll also consider the other patch <https://reviews.llvm.org/D128269> on hold until you fix this one (since it might need at least a rebase afterwards). Thanks for looking into it!


Repository:
  rT test-suite

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128262/new/

https://reviews.llvm.org/D128262



More information about the flang-commits mailing list