| 1 |
! RUN: %flang_fc1 -fdebug-dump-parse-tree -fopenmp %s | FileCheck %s |
| 2 |
|
| 3 |
program openmp_parse_if |
| 4 |
logical :: cond |
| 5 |
integer :: i |
| 6 |
|
| 7 |
! CHECK: OmpSimpleStandaloneDirective -> llvm::omp::Directive = target update |
| 8 |
! CHECK-NEXT: OmpClause -> If -> OmpIfClause |
| 9 |
! CHECK-NOT: DirectiveNameModifier |
| 10 |
!$omp target update if(cond) to(i) |
| 11 |
|
| 12 |
! CHECK: OmpSimpleStandaloneDirective -> llvm::omp::Directive = target update |
| 13 |
! CHECK-NEXT: OmpClause -> If -> OmpIfClause |
| 14 |
! CHECK-NEXT: DirectiveNameModifier = TargetUpdate |
| 15 |
!$omp target update if(target update: cond) to(i) |
| 16 |
|
| 17 |
! CHECK: OmpSimpleStandaloneDirective -> llvm::omp::Directive = target enter data |
| 18 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 19 |
! CHECK-NEXT: DirectiveNameModifier = TargetEnterData |
| 20 |
!$omp target enter data map(to: i) if(target enter data: cond) |
| 21 |
|
| 22 |
! CHECK: OmpSimpleStandaloneDirective -> llvm::omp::Directive = target exit data |
| 23 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 24 |
! CHECK-NEXT: DirectiveNameModifier = TargetExitData |
| 25 |
!$omp target exit data map(from: i) if(target exit data: cond) |
| 26 |
|
| 27 |
! CHECK: OmpBlockDirective -> llvm::omp::Directive = target data |
| 28 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 29 |
! CHECK-NEXT: DirectiveNameModifier = TargetData |
| 30 |
!$omp target data map(tofrom: i) if(target data: cond) |
| 31 |
!$omp end target data |
| 32 |
|
| 33 |
! CHECK: OmpLoopDirective -> llvm::omp::Directive = target teams distribute parallel do simd |
| 34 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 35 |
! CHECK-NEXT: DirectiveNameModifier = Target |
| 36 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 37 |
! CHECK-NEXT: DirectiveNameModifier = Teams |
| 38 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 39 |
! CHECK-NEXT: DirectiveNameModifier = Parallel |
| 40 |
! CHECK: OmpClause -> If -> OmpIfClause |
| 41 |
! CHECK-NEXT: DirectiveNameModifier = Simd |
| 42 |
!$omp target teams distribute parallel do simd if(target: cond) & |
| 43 |
!$omp& if(teams: cond) if(parallel: cond) if(simd: cond) |
| 44 |
do i = 1, 10 |
| 45 |
end do |
| 46 |
!$omp end target teams distribute parallel do simd |
| 47 |
|
| 48 |
! CHECK: OmpBlockDirective -> llvm::omp::Directive = task |
| 49 |
! CHECK-NEXT: OmpClause -> If -> OmpIfClause |
| 50 |
! CHECK-NEXT: DirectiveNameModifier = Task |
| 51 |
!$omp task if(task: cond) |
| 52 |
!$omp end task |
| 53 |
|
| 54 |
! CHECK: OmpLoopDirective -> llvm::omp::Directive = taskloop |
| 55 |
! CHECK-NEXT: OmpClause -> If -> OmpIfClause |
| 56 |
! CHECK-NEXT: DirectiveNameModifier = Taskloop |
| 57 |
!$omp taskloop if(taskloop: cond) |
| 58 |
do i = 1, 10 |
| 59 |
end do |
| 60 |
!$omp end taskloop |
| 61 |
end program openmp_parse_if |