diff options
author | Faris Rehman <faris.rehman@arm.com> | 2021-01-25 12:07:17 +0000 |
---|---|---|
committer | Faris Rehman <faris.rehman@arm.com> | 2021-01-25 12:32:23 +0000 |
commit | 1c8f199f449916d30ec12ecc5bb0f157ab1d01a0 (patch) | |
tree | b825514ca72e7cb59e120095d637a0bca84fc9ae /flang | |
parent | 171d12489f20818e292362342b5665c689073ad2 (diff) | |
download | llvm-1c8f199f449916d30ec12ecc5bb0f157ab1d01a0.zip llvm-1c8f199f449916d30ec12ecc5bb0f157ab1d01a0.tar.gz llvm-1c8f199f449916d30ec12ecc5bb0f157ab1d01a0.tar.bz2 |
[flang][driver] Update PP tests to use the new driver
Update the preprocessor regression tests to use the new driver if the new driver is built (FLANG_BUILD_NEW_DRIVER=On), otherwise the tests will still run using f18.
Summary of changes:
- Introduce %flang to the regression tests, which points to the new driver if it is built or otherwise points to f18
- Update all tests in flang/test/Preprocessing/ to use %flang
Differential Revision: https://reviews.llvm.org/D94805
Diffstat (limited to 'flang')
81 files changed, 85 insertions, 80 deletions
diff --git a/flang/test/Preprocessing/assert.F90 b/flang/test/Preprocessing/assert.F90 index 64d49e6..5d4837e 100644 --- a/flang/test/Preprocessing/assert.F90 +++ b/flang/test/Preprocessing/assert.F90 @@ -1,4 +1,4 @@ -!RUN: %f18 -E %s 2>&1 | FileCheck %s +!RUN: %flang -E %s 2>&1 | FileCheck %s !CHECK: if(.not.(.true.)) error stop "assert(" // ".TRUE." // ") failed " // "at "" !CHECK-SAME: assert.F90"": " // "7" #define STR(x) #x diff --git a/flang/test/Preprocessing/compiler_defined_macros.F90 b/flang/test/Preprocessing/compiler_defined_macros.F90 index ba20f6d..f5f955b 100644 --- a/flang/test/Preprocessing/compiler_defined_macros.F90 +++ b/flang/test/Preprocessing/compiler_defined_macros.F90 @@ -3,7 +3,7 @@ !CHECK: flang_major = {{[1-9][0-9]*$}} !CHECK: flang_minor = {{[0-9]+$}} !CHECK: flang_patchlevel = {{[0-9]+$}} -!RUN: %f18 -E %s | FileCheck --ignore-case %s +!RUN: %flang -E %s | FileCheck --ignore-case %s integer, parameter :: flang_major = __flang_major__ diff --git a/flang/test/Preprocessing/defines.F90 b/flang/test/Preprocessing/defines.F90 index 449c54c..d59789f 100644 --- a/flang/test/Preprocessing/defines.F90 +++ b/flang/test/Preprocessing/defines.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E -DFOO=1 -DBAR=2 %s | FileCheck %s +! RUN: %flang -E -DFOO=1 -DBAR=2 %s | FileCheck %s ! CHECK: integer :: a = 1 integer :: a = FOO diff --git a/flang/test/Preprocessing/fixed-rescan.F b/flang/test/Preprocessing/fixed-rescan.F index 3d6ba9a..ac983e7c 100644 --- a/flang/test/Preprocessing/fixed-rescan.F +++ b/flang/test/Preprocessing/fixed-rescan.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s | FileCheck %s +! RUN: %flang -E %s | FileCheck %s ! CHECK: callbar ! Ensure that rescanned lines after macro replacement are not ! misinterpreted as fixed-form comments when they start with C or D. diff --git a/flang/test/Preprocessing/hollerith.f b/flang/test/Preprocessing/hollerith.f index 0c920e0..5f20259 100644 --- a/flang/test/Preprocessing/hollerith.f +++ b/flang/test/Preprocessing/hollerith.f @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: character*1hi ! CHECK: dataa/1*1h / ! CHECK: datab/1*1h / diff --git a/flang/test/Preprocessing/include-comment.F90 b/flang/test/Preprocessing/include-comment.F90 index 6ac475f..239d9b7 100644 --- a/flang/test/Preprocessing/include-comment.F90 +++ b/flang/test/Preprocessing/include-comment.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -I%S -E %s 2>&1 | FileCheck %s +! RUN: %flang -I%S -E %s 2>&1 | FileCheck %s ! CHECK-NOT: :3: #include <empty.h> ! comment ! CHECK-NOT: :5: diff --git a/flang/test/Preprocessing/pp001.F b/flang/test/Preprocessing/pp001.F index 9519864..455da73 100644 --- a/flang/test/Preprocessing/pp001.F +++ b/flang/test/Preprocessing/pp001.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then * keyword macros integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp002.F b/flang/test/Preprocessing/pp002.F index b4cbd75..d673fcd 100644 --- a/flang/test/Preprocessing/pp002.F +++ b/flang/test/Preprocessing/pp002.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm.eq.777)then * #undef integer, parameter :: KWM = 777 diff --git a/flang/test/Preprocessing/pp003.F b/flang/test/Preprocessing/pp003.F index 4df10c4..2062dbc 100644 --- a/flang/test/Preprocessing/pp003.F +++ b/flang/test/Preprocessing/pp003.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * function-like macros integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp004.F b/flang/test/Preprocessing/pp004.F index 788d368..f5724df 100644 --- a/flang/test/Preprocessing/pp004.F +++ b/flang/test/Preprocessing/pp004.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm.eq.777)then * KWMs case-sensitive integer, parameter :: KWM = 777 diff --git a/flang/test/Preprocessing/pp005.F b/flang/test/Preprocessing/pp005.F index 390e662..48cf12d 100644 --- a/flang/test/Preprocessing/pp005.F +++ b/flang/test/Preprocessing/pp005.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=777 * KWM split across continuation, implicit padding integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp006.F b/flang/test/Preprocessing/pp006.F index 3c44728..f878bfd 100644 --- a/flang/test/Preprocessing/pp006.F +++ b/flang/test/Preprocessing/pp006.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=777 * ditto, but with intervening *comment line integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp007.F b/flang/test/Preprocessing/pp007.F index ca78f4f..a5d871a 100644 --- a/flang/test/Preprocessing/pp007.F +++ b/flang/test/Preprocessing/pp007.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=kwm * KWM split across continuation, clipped after column 72 integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp008.F b/flang/test/Preprocessing/pp008.F index 9dd7bd9..7e580ef 100644 --- a/flang/test/Preprocessing/pp008.F +++ b/flang/test/Preprocessing/pp008.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=kwm * KWM with spaces in name at invocation NOT replaced integer, parameter :: KWM = 777 diff --git a/flang/test/Preprocessing/pp009.F b/flang/test/Preprocessing/pp009.F index c29021d..b6a6249 100644 --- a/flang/test/Preprocessing/pp009.F +++ b/flang/test/Preprocessing/pp009.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call split across continuation, implicit padding integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp010.F b/flang/test/Preprocessing/pp010.F index 4a812cd..e860bd9 100644 --- a/flang/test/Preprocessing/pp010.F +++ b/flang/test/Preprocessing/pp010.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * ditto, but with intervening *comment line integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp011.F b/flang/test/Preprocessing/pp011.F index c106c8b..af0e0e8 100644 --- a/flang/test/Preprocessing/pp011.F +++ b/flang/test/Preprocessing/pp011.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=iflm(666) * FLM call name split across continuation, clipped integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp012.F b/flang/test/Preprocessing/pp012.F index 411cfb8..12ab612 100644 --- a/flang/test/Preprocessing/pp012.F +++ b/flang/test/Preprocessing/pp012.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call name split across continuation integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp013.F b/flang/test/Preprocessing/pp013.F index f05e2e3..07bb25e 100644 --- a/flang/test/Preprocessing/pp013.F +++ b/flang/test/Preprocessing/pp013.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call split between name and ( integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp014.F b/flang/test/Preprocessing/pp014.F index 4709660..7ac5d38 100644 --- a/flang/test/Preprocessing/pp014.F +++ b/flang/test/Preprocessing/pp014.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call split between name and (, with intervening *comment integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp015.F b/flang/test/Preprocessing/pp015.F index 8320bd7..700da10 100644 --- a/flang/test/Preprocessing/pp015.F +++ b/flang/test/Preprocessing/pp015.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call split between name and (, clipped integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp016.F b/flang/test/Preprocessing/pp016.F index 95c89f8..c5d90e7 100644 --- a/flang/test/Preprocessing/pp016.F +++ b/flang/test/Preprocessing/pp016.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call split between name and ( and in argument integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp017.F b/flang/test/Preprocessing/pp017.F index a11f185..49fff58 100644 --- a/flang/test/Preprocessing/pp017.F +++ b/flang/test/Preprocessing/pp017.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then * KLM rescan integer, parameter :: KWM = 666, KWM2 = 667 diff --git a/flang/test/Preprocessing/pp018.F b/flang/test/Preprocessing/pp018.F index 69c24e5..d6a4216 100644 --- a/flang/test/Preprocessing/pp018.F +++ b/flang/test/Preprocessing/pp018.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm2.eq.777)then * KLM rescan with #undef (so rescan is after expansion) integer, parameter :: KWM2 = 777, KWM = 667 diff --git a/flang/test/Preprocessing/pp019.F b/flang/test/Preprocessing/pp019.F index d607ad3..a8c0ff6 100644 --- a/flang/test/Preprocessing/pp019.F +++ b/flang/test/Preprocessing/pp019.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM rescan integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp020.F b/flang/test/Preprocessing/pp020.F index 8852500..9fe9630 100644 --- a/flang/test/Preprocessing/pp020.F +++ b/flang/test/Preprocessing/pp020.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((111)+666) * FLM expansion of argument integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp021.F b/flang/test/Preprocessing/pp021.F index 1662a68..2936264 100644 --- a/flang/test/Preprocessing/pp021.F +++ b/flang/test/Preprocessing/pp021.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch='KWM' ! CHECK: if(ch.eq.'KWM')then * KWM NOT expanded in 'literal' diff --git a/flang/test/Preprocessing/pp022.F b/flang/test/Preprocessing/pp022.F index 026c02e..647b683 100644 --- a/flang/test/Preprocessing/pp022.F +++ b/flang/test/Preprocessing/pp022.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch="KWM" ! CHECK: if(ch.eq.'KWM')then * KWM NOT expanded in "literal" diff --git a/flang/test/Preprocessing/pp023.F b/flang/test/Preprocessing/pp023.F index a0d053f..ecad31b 100644 --- a/flang/test/Preprocessing/pp023.F +++ b/flang/test/Preprocessing/pp023.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch=3hKWM ! CHECK: if(ch.eq.'KWM')then * KWM NOT expanded in 9HHOLLERITH literal diff --git a/flang/test/Preprocessing/pp024.F b/flang/test/Preprocessing/pp024.F index 6ea76cc..7f8e3bb 100644 --- a/flang/test/Preprocessing/pp024.F +++ b/flang/test/Preprocessing/pp024.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: 100format(3hKWM) ! CHECK: if(ch.eq.'KWM')then * KWM NOT expanded in Hollerith in FORMAT diff --git a/flang/test/Preprocessing/pp025.F b/flang/test/Preprocessing/pp025.F index 49521d4..bb7bc21 100644 --- a/flang/test/Preprocessing/pp025.F +++ b/flang/test/Preprocessing/pp025.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=ikwm2z * KWM expansion is before token pasting due to fixed-form space removal integer, parameter :: IKWM2Z = 777 diff --git a/flang/test/Preprocessing/pp026.F b/flang/test/Preprocessing/pp026.F index b551f3b..e377001 100644 --- a/flang/test/Preprocessing/pp026.F +++ b/flang/test/Preprocessing/pp026.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((111)+666) * ## token pasting works in FLM integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp027.F b/flang/test/Preprocessing/pp027.F index c1b787f..577bd48 100644 --- a/flang/test/Preprocessing/pp027.F +++ b/flang/test/Preprocessing/pp027.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: kwm=666 ! CHECK: if(777.eq.777)then * #DEFINE works in fixed form diff --git a/flang/test/Preprocessing/pp028.F b/flang/test/Preprocessing/pp028.F index 51eab84f..3530628 100644 --- a/flang/test/Preprocessing/pp028.F +++ b/flang/test/Preprocessing/pp028.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=kw * fixed-form clipping done before KWM expansion on source line integer, parameter :: KW = 777 diff --git a/flang/test/Preprocessing/pp029.F b/flang/test/Preprocessing/pp029.F index 9be309f..23c0d337 100644 --- a/flang/test/Preprocessing/pp029.F +++ b/flang/test/Preprocessing/pp029.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then * \ newline allowed in #define integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp030.F b/flang/test/Preprocessing/pp030.F index c04cf94..91b1217 100644 --- a/flang/test/Preprocessing/pp030.F +++ b/flang/test/Preprocessing/pp030.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then * /* C comment */ erased from #define integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp031.F b/flang/test/Preprocessing/pp031.F index 90b1464..d828616 100644 --- a/flang/test/Preprocessing/pp031.F +++ b/flang/test/Preprocessing/pp031.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777//ccomment.eq.777)then ! CHECK: print*,'pp031.F no: ',777//ccomment * // C++ comment NOT erased from #define diff --git a/flang/test/Preprocessing/pp032.F b/flang/test/Preprocessing/pp032.F index 6b77914..22350e7 100644 --- a/flang/test/Preprocessing/pp032.F +++ b/flang/test/Preprocessing/pp032.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then ! CHECK: print*,'pp032.F no: ',777 * /* C comment */ \ newline erased from #define diff --git a/flang/test/Preprocessing/pp033.F b/flang/test/Preprocessing/pp033.F index 3364527..1b32ae6 100644 --- a/flang/test/Preprocessing/pp033.F +++ b/flang/test/Preprocessing/pp033.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then ! CHECK: print*,'pp033.F no: ',777 * /* C comment \ newline */ erased from #define diff --git a/flang/test/Preprocessing/pp034.F b/flang/test/Preprocessing/pp034.F index 0c64aca..d9f8a72 100644 --- a/flang/test/Preprocessing/pp034.F +++ b/flang/test/Preprocessing/pp034.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then ! CHECK: print*,'pp034.F no: ',777 * \ newline allowed in name on KWM definition diff --git a/flang/test/Preprocessing/pp035.F b/flang/test/Preprocessing/pp035.F index 8081741..0c0152a 100644 --- a/flang/test/Preprocessing/pp035.F +++ b/flang/test/Preprocessing/pp035.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777.eq.777)then ! CHECK: print*,'pp035.F no: ',777 * #if 2 .LT. 3 works diff --git a/flang/test/Preprocessing/pp036.F b/flang/test/Preprocessing/pp036.F index b7024c4..7894255 100644 --- a/flang/test/Preprocessing/pp036.F +++ b/flang/test/Preprocessing/pp036.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(.true.)then ! CHECK: print*,'pp036.F no: ',.true. * #define FALSE TRUE ... .FALSE. -> .TRUE. diff --git a/flang/test/Preprocessing/pp037.F b/flang/test/Preprocessing/pp037.F index 52bfa8f..93c9b28 100644 --- a/flang/test/Preprocessing/pp037.F +++ b/flang/test/Preprocessing/pp037.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(7777.eq.777)then ! CHECK: print*,'pp037.F no: ',7777 * fixed-form clipping NOT applied to #define diff --git a/flang/test/Preprocessing/pp038.F b/flang/test/Preprocessing/pp038.F index 7386aee..655551b 100644 --- a/flang/test/Preprocessing/pp038.F +++ b/flang/test/Preprocessing/pp038.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=((666)+111) * FLM call with closing ')' on next line (not a continuation) integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp039.F b/flang/test/Preprocessing/pp039.F index 9124474..f80e0b0 100644 --- a/flang/test/Preprocessing/pp039.F +++ b/flang/test/Preprocessing/pp039.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res=iflm ! CHECK: (666) ! CHECK-NOT: res=((666)+111) diff --git a/flang/test/Preprocessing/pp040.F b/flang/test/Preprocessing/pp040.F index d589c38..a3c2a6b 100644 --- a/flang/test/Preprocessing/pp040.F +++ b/flang/test/Preprocessing/pp040.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK-NOT: FAIL HARD! * #define KWM c, then KWM works as comment line initiator #define KWM c diff --git a/flang/test/Preprocessing/pp041.F b/flang/test/Preprocessing/pp041.F index dcf6153..9bc04db 100644 --- a/flang/test/Preprocessing/pp041.F +++ b/flang/test/Preprocessing/pp041.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: j=666wmj=j+1wm211 * use KWM expansion as continuation indicators #define KWM 0 diff --git a/flang/test/Preprocessing/pp042.F b/flang/test/Preprocessing/pp042.F index d5cc46a..e5a679e 100644 --- a/flang/test/Preprocessing/pp042.F +++ b/flang/test/Preprocessing/pp042.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK-NOT: goto 2 * #define c 1, then use c as label in fixed-form #define c 1 diff --git a/flang/test/Preprocessing/pp043.F b/flang/test/Preprocessing/pp043.F index a079466..d8ed6b1 100644 --- a/flang/test/Preprocessing/pp043.F +++ b/flang/test/Preprocessing/pp043.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm.eq.777)then * #define with # in column 6 is a continuation line in fixed-form integer, parameter :: defineKWM666 = 555 diff --git a/flang/test/Preprocessing/pp044.F b/flang/test/Preprocessing/pp044.F index c14b29c..a699c08 100644 --- a/flang/test/Preprocessing/pp044.F +++ b/flang/test/Preprocessing/pp044.F @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK-NOT:z=111 * #define directive amid continuations integer, parameter :: KWM = 222, KWM111 = 333, KWM222 = 555 diff --git a/flang/test/Preprocessing/pp101.F90 b/flang/test/Preprocessing/pp101.F90 index b0f8601..dbf2aa9 100644 --- a/flang/test/Preprocessing/pp101.F90 +++ b/flang/test/Preprocessing/pp101.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777 .eq. 777) then ! keyword macros integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp102.F90 b/flang/test/Preprocessing/pp102.F90 index e2c3207..73d931a 100644 --- a/flang/test/Preprocessing/pp102.F90 +++ b/flang/test/Preprocessing/pp102.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm .eq. 777) then ! #undef integer, parameter :: KWM = 777 diff --git a/flang/test/Preprocessing/pp103.F90 b/flang/test/Preprocessing/pp103.F90 index 3309d7f..0384d8c 100644 --- a/flang/test/Preprocessing/pp103.F90 +++ b/flang/test/Preprocessing/pp103.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! function-like macros integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp104.F90 b/flang/test/Preprocessing/pp104.F90 index 51248c2..95653ff 100644 --- a/flang/test/Preprocessing/pp104.F90 +++ b/flang/test/Preprocessing/pp104.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm .eq. 777) then ! KWMs case-sensitive integer, parameter :: KWM = 777 diff --git a/flang/test/Preprocessing/pp105.F90 b/flang/test/Preprocessing/pp105.F90 index 898a4a1..b4f73da 100644 --- a/flang/test/Preprocessing/pp105.F90 +++ b/flang/test/Preprocessing/pp105.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = 777 ! KWM call name split across continuation, with leading & integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp106.F90 b/flang/test/Preprocessing/pp106.F90 index d83085f..556d779 100644 --- a/flang/test/Preprocessing/pp106.F90 +++ b/flang/test/Preprocessing/pp106.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = 777 ! ditto, with & ! comment integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp107.F90 b/flang/test/Preprocessing/pp107.F90 index 6973127..51aa750 100644 --- a/flang/test/Preprocessing/pp107.F90 +++ b/flang/test/Preprocessing/pp107.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = kwm ! KWM call name split across continuation, no leading &, with & ! comment integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp108.F90 b/flang/test/Preprocessing/pp108.F90 index b07ec98..d891bf3 100644 --- a/flang/test/Preprocessing/pp108.F90 +++ b/flang/test/Preprocessing/pp108.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = kwm ! ditto, but without & ! comment integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp109.F90 b/flang/test/Preprocessing/pp109.F90 index e75fd10..b488049 100644 --- a/flang/test/Preprocessing/pp109.F90 +++ b/flang/test/Preprocessing/pp109.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! FLM call name split with leading & integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp110.F90 b/flang/test/Preprocessing/pp110.F90 index 681408e..3f6180c 100644 --- a/flang/test/Preprocessing/pp110.F90 +++ b/flang/test/Preprocessing/pp110.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! ditto, with & ! comment integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp111.F90 b/flang/test/Preprocessing/pp111.F90 index 4b49bf6..b0b1219 100644 --- a/flang/test/Preprocessing/pp111.F90 +++ b/flang/test/Preprocessing/pp111.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm (666) ! FLM call name split across continuation, no leading &, with & ! comment integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp112.F90 b/flang/test/Preprocessing/pp112.F90 index 9828366..1a3cf3f 100644 --- a/flang/test/Preprocessing/pp112.F90 +++ b/flang/test/Preprocessing/pp112.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm (666) ! ditto, but without & ! comment integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp113.F90 b/flang/test/Preprocessing/pp113.F90 index 56e3438..9604316 100644 --- a/flang/test/Preprocessing/pp113.F90 +++ b/flang/test/Preprocessing/pp113.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! FLM call split across continuation between name and (, leading & integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp114.F90 b/flang/test/Preprocessing/pp114.F90 index 4c44759..c44ca7d 100644 --- a/flang/test/Preprocessing/pp114.F90 +++ b/flang/test/Preprocessing/pp114.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! ditto, with & ! comment, leading & integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp115.F90 b/flang/test/Preprocessing/pp115.F90 index 290f62e..29b5802 100644 --- a/flang/test/Preprocessing/pp115.F90 +++ b/flang/test/Preprocessing/pp115.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm (666) ! ditto, with & ! comment, no leading & integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp116.F90 b/flang/test/Preprocessing/pp116.F90 index d41fab7..9e070ba 100644 --- a/flang/test/Preprocessing/pp116.F90 +++ b/flang/test/Preprocessing/pp116.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm (666) ! FLM call split between name and (, no leading & integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp117.F90 b/flang/test/Preprocessing/pp117.F90 index c8d1c2f..bb0692c 100644 --- a/flang/test/Preprocessing/pp117.F90 +++ b/flang/test/Preprocessing/pp117.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777 .eq. 777) then ! KWM rescan integer, parameter :: KWM = 666, KWM2 = 667 diff --git a/flang/test/Preprocessing/pp118.F90 b/flang/test/Preprocessing/pp118.F90 index e71cc41..fe24d83 100644 --- a/flang/test/Preprocessing/pp118.F90 +++ b/flang/test/Preprocessing/pp118.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(kwm2 .eq. 777) then ! KWM rescan with #undef, proving rescan after expansion integer, parameter :: KWM2 = 777, KWM = 667 diff --git a/flang/test/Preprocessing/pp119.F90 b/flang/test/Preprocessing/pp119.F90 index ea9a15c..514bff0 100644 --- a/flang/test/Preprocessing/pp119.F90 +++ b/flang/test/Preprocessing/pp119.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((666)+111) ! FLM rescan integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp120.F90 b/flang/test/Preprocessing/pp120.F90 index 9c4b88c..510550b 100644 --- a/flang/test/Preprocessing/pp120.F90 +++ b/flang/test/Preprocessing/pp120.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = ((111)+666) ! FLM expansion of argument integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp121.F90 b/flang/test/Preprocessing/pp121.F90 index cdf25e15..900e255 100644 --- a/flang/test/Preprocessing/pp121.F90 +++ b/flang/test/Preprocessing/pp121.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch = 'KWM' ! CHECK: if(ch .eq. 'KWM') then ! KWM NOT expanded in 'literal' diff --git a/flang/test/Preprocessing/pp122.F90 b/flang/test/Preprocessing/pp122.F90 index 14c8762..8051cbd 100644 --- a/flang/test/Preprocessing/pp122.F90 +++ b/flang/test/Preprocessing/pp122.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch = "KWM" ! KWM NOT expanded in "literal" #define KWM 666 diff --git a/flang/test/Preprocessing/pp123.F90 b/flang/test/Preprocessing/pp123.F90 index 1768cec..8181b68 100644 --- a/flang/test/Preprocessing/pp123.F90 +++ b/flang/test/Preprocessing/pp123.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: ch = 3hKWM ! KWM NOT expanded in Hollerith literal #define KWM 666 diff --git a/flang/test/Preprocessing/pp124.F90 b/flang/test/Preprocessing/pp124.F90 index bb01151..750f9fa 100644 --- a/flang/test/Preprocessing/pp124.F90 +++ b/flang/test/Preprocessing/pp124.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: 100 format(3hKWM) ! KWM NOT expanded in Hollerith in FORMAT #define KWM 666 diff --git a/flang/test/Preprocessing/pp125.F90 b/flang/test/Preprocessing/pp125.F90 index cf3909b..86abccc 100644 --- a/flang/test/Preprocessing/pp125.F90 +++ b/flang/test/Preprocessing/pp125.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777 .eq. 777) then ! #DEFINE works in free form integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp126.F90 b/flang/test/Preprocessing/pp126.F90 index fefb7fc..f41af1e 100644 --- a/flang/test/Preprocessing/pp126.F90 +++ b/flang/test/Preprocessing/pp126.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: if(777 .eq. 777) then ! \ newline works in #define integer, parameter :: KWM = 666 diff --git a/flang/test/Preprocessing/pp127.F90 b/flang/test/Preprocessing/pp127.F90 index 08feedf..09de8ed 100644 --- a/flang/test/Preprocessing/pp127.F90 +++ b/flang/test/Preprocessing/pp127.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm(666 ) ! FLM call with closing ')' on next line (not a continuation) integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp128.F90 b/flang/test/Preprocessing/pp128.F90 index 46918e0..a8bc792 100644 --- a/flang/test/Preprocessing/pp128.F90 +++ b/flang/test/Preprocessing/pp128.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK: res = iflm ! FLM call with '(' on next line (not a continuation) integer function IFLM(x) diff --git a/flang/test/Preprocessing/pp129.F90 b/flang/test/Preprocessing/pp129.F90 index ab7e7f0..dee4c7b 100644 --- a/flang/test/Preprocessing/pp129.F90 +++ b/flang/test/Preprocessing/pp129.F90 @@ -1,4 +1,4 @@ -! RUN: %f18 -E %s 2>&1 | FileCheck %s +! RUN: %flang -E %s 2>&1 | FileCheck %s ! CHECK-NOT: stop ! #define KWM !, then KWM works as comment line initiator #define KWM ! diff --git a/flang/test/Preprocessing/pp130.F90 b/flang/test/Preprocessing/pp130.F90 index be11488..8066e28 100644 --- a/flang/test/Preprocessing/pp130.F90 +++ b/flang/test/Preprocessing/pp130.F90 @@ -1,4 +1,4 @@ -! RUN: (%f18 -E %s 2>&1 || true) | FileCheck %s +! RUN: (%flang -E %s 2>&1 || true) | FileCheck %s ! CHECK: error: bad character ('&') in Fortran token ! #define KWM &, use for continuation w/o pasting (ifort and nag seem to continue #define) #define KWM & diff --git a/flang/test/lit.cfg.py b/flang/test/lit.cfg.py index c9992b7..d724628 100644 --- a/flang/test/lit.cfg.py +++ b/flang/test/lit.cfg.py @@ -73,6 +73,11 @@ tools = [ if config.include_flang_new_driver_test: tools.append(ToolSubst('%flang-new', command=FindTool('flang-new'), unresolved='fatal')) + tools.append(ToolSubst('%flang', command=FindTool('flang-new'), unresolved='fatal')) +else: + tools.append(ToolSubst('%flang', command=FindTool('f18'), + extra_args=["-intrinsic-module-directory "+config.flang_intrinsic_modules_dir], + unresolved='fatal')) if config.flang_standalone_build: llvm_config.add_tool_substitutions(tools, [config.flang_llvm_tools_dir]) |