brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.7 KiB · 644ab3f Raw
65 lines · plain
1! RUN: %flang_fc1 -E %s 2>&1 | FileCheck %s --strict-whitespace --check-prefix=CHECK-E2! RUN: %flang_fc1 -fopenmp -fdebug-unparse %s 2>&1 | FileCheck %s --check-prefix=CHECK-OMP3! RUN: %flang_fc1 -fdebug-unparse %s 2>&1 | FileCheck %s --check-prefix=CHECK-NO-OMP4 5! Test in mixed way, i.e., combination of Fortran free source form6! and free source form with conditional compilation sentinel.7! CHECK-LABEL: subroutine mixed_form1()8! CHECK-E:{{^}}      i = 1 &9! CHECK-E:{{^}}!$    +100&10! CHECK-E:{{^}}!$   &+ 1000&11! CHECK-E:{{^}}     &+ 10 + 1&12! CHECK-E:{{^}}!$   & +100000&13! CHECK-E:{{^}}     &0000 + 100000014! CHECK-OMP: i=1001001112_415! CHECK-NO-OMP: i=1010011_416subroutine mixed_form1()17   i = 1 &18  !$ +100&19  !$&+ 1000&20   &+ 10 + 1&21  !$& +100000&22   &0000 + 100000023end subroutine24 25! Testing continuation lines in only Fortran Free form Source26! CHECK-LABEL: subroutine mixed_form2()27! CHECK-E:{{^}}      i = 1 +10 +100 + 1000 + 1000028! CHECK-OMP: i=11111_429! CHECK-NO-OMP: i=11111_430subroutine mixed_form2()31   i = 1 &32   +10 &33   &+10034   & + 1000 &35   + 1000036end subroutine37 38! Testing continuation line in only free source form conditional compilation sentinel.39! CHECK-LABEL: subroutine mixed_form3()40! CHECK-E:{{^}}!$    i=041! CHECK-E:{{^}}!$    i = 1 &42! CHECK-E:{{^}}!$   & +10 &43! CHECK-E:{{^}}!$   &+100&44! CHECK-E:{{^}}!$    +100045! CHECK-OMP: i=0_446! CHECK-OMP: i=1111_447! CHECK-NO-OMP-NOT: i=0_448subroutine mixed_form3()49   !$ i=050   !$ i = 1 &51   !$ & +10 &52   !$&+100&53   !$ +100054end subroutine55 56! CHECK-LABEL: subroutine regression57! CHECK-E:{{^}}!$    real x, &58! CHECK-E:{{^}}      stop59! CHECK-OMP: REAL x, stop60! CHECK-NO-OMP-NOT: REAL x,61subroutine regression62!$ real x, &63 stop64end65