|  | 
|  | 1 | +!RUN: %flang_fc1 -fdebug-unparse -fopenmp -fopenmp-version=60 %s | FileCheck --ignore-case --check-prefix="UNPARSE" %s | 
|  | 2 | +!RUN: %flang_fc1 -fdebug-dump-parse-tree -fopenmp -fopenmp-version=60 %s | FileCheck --check-prefix="PARSE-TREE" %s | 
|  | 3 | + | 
|  | 4 | +subroutine f00 | 
|  | 5 | +  !$omp taskgraph | 
|  | 6 | +  block | 
|  | 7 | +  end block | 
|  | 8 | +end | 
|  | 9 | + | 
|  | 10 | +!UNPARSE: SUBROUTINE f00 | 
|  | 11 | +!UNPARSE: !$OMP TASKGRAPH | 
|  | 12 | +!UNPARSE:  BLOCK | 
|  | 13 | +!UNPARSE:  END BLOCK | 
|  | 14 | +!UNPARSE: END SUBROUTINE | 
|  | 15 | + | 
|  | 16 | +!PARSE-TREE: ExecutionPartConstruct -> ExecutableConstruct -> OpenMPConstruct -> OmpBlockConstruct | 
|  | 17 | +!PARSE-TREE: | OmpBeginDirective | 
|  | 18 | +!PARSE-TREE: | | OmpDirectiveName -> llvm::omp::Directive = taskgraph | 
|  | 19 | +!PARSE-TREE: | | OmpClauseList -> | 
|  | 20 | +!PARSE-TREE: | | Flags = None | 
|  | 21 | +!PARSE-TREE: | Block | 
|  | 22 | +!PARSE-TREE: | | ExecutionPartConstruct -> ExecutableConstruct -> BlockConstruct | 
|  | 23 | +!PARSE-TREE: | | | BlockStmt -> | 
|  | 24 | +!PARSE-TREE: | | | BlockSpecificationPart -> SpecificationPart | 
|  | 25 | +!PARSE-TREE: | | | | ImplicitPart -> | 
|  | 26 | +!PARSE-TREE: | | | Block | 
|  | 27 | +!PARSE-TREE: | | | EndBlockStmt -> | 
|  | 28 | + | 
|  | 29 | + | 
|  | 30 | +subroutine f01(x, y) | 
|  | 31 | +  integer :: x | 
|  | 32 | +  logical :: y | 
|  | 33 | +  !$omp taskgraph graph_id(x) graph_reset(y) | 
|  | 34 | +  !$omp task | 
|  | 35 | +    continue | 
|  | 36 | +  !$omp end task | 
|  | 37 | +  !$omp end taskgraph | 
|  | 38 | +end | 
|  | 39 | + | 
|  | 40 | +!UNPARSE: SUBROUTINE f01 (x, y) | 
|  | 41 | +!UNPARSE:  INTEGER x | 
|  | 42 | +!UNPARSE:  LOGICAL y | 
|  | 43 | +!UNPARSE: !$OMP TASKGRAPH GRAPH_ID(x) GRAPH_RESET(y) | 
|  | 44 | +!UNPARSE: !$OMP TASK | 
|  | 45 | +!UNPARSE:  CONTINUE | 
|  | 46 | +!UNPARSE: !$OMP END TASK | 
|  | 47 | +!UNPARSE: !$OMP END TASKGRAPH | 
|  | 48 | +!UNPARSE: END SUBROUTINE | 
|  | 49 | + | 
|  | 50 | +!PARSE-TREE: ExecutionPartConstruct -> ExecutableConstruct -> OpenMPConstruct -> OmpBlockConstruct | 
|  | 51 | +!PARSE-TREE: | OmpBeginDirective | 
|  | 52 | +!PARSE-TREE: | | OmpDirectiveName -> llvm::omp::Directive = taskgraph | 
|  | 53 | +!PARSE-TREE: | | OmpClauseList -> OmpClause -> GraphId -> OmpGraphIdClause -> Expr = 'x' | 
|  | 54 | +!PARSE-TREE: | | | Designator -> DataRef -> Name = 'x' | 
|  | 55 | +!PARSE-TREE: | | OmpClause -> GraphReset -> OmpGraphResetClause -> Expr = 'y' | 
|  | 56 | +!PARSE-TREE: | | | Designator -> DataRef -> Name = 'y' | 
|  | 57 | +!PARSE-TREE: | | Flags = None | 
|  | 58 | +!PARSE-TREE: | Block | 
|  | 59 | +!PARSE-TREE: | | ExecutionPartConstruct -> ExecutableConstruct -> OpenMPConstruct -> OmpBlockConstruct | 
|  | 60 | +!PARSE-TREE: | | | OmpBeginDirective | 
|  | 61 | +!PARSE-TREE: | | | | OmpDirectiveName -> llvm::omp::Directive = task | 
|  | 62 | +!PARSE-TREE: | | | | OmpClauseList -> | 
|  | 63 | +!PARSE-TREE: | | | | Flags = None | 
|  | 64 | +!PARSE-TREE: | | | Block | 
|  | 65 | +!PARSE-TREE: | | | | ExecutionPartConstruct -> ExecutableConstruct -> ActionStmt -> ContinueStmt | 
|  | 66 | +!PARSE-TREE: | | | OmpEndDirective | 
|  | 67 | +!PARSE-TREE: | | | | OmpDirectiveName -> llvm::omp::Directive = task | 
|  | 68 | +!PARSE-TREE: | | | | OmpClauseList -> | 
|  | 69 | +!PARSE-TREE: | | | | Flags = None | 
|  | 70 | +!PARSE-TREE: | OmpEndDirective | 
|  | 71 | +!PARSE-TREE: | | OmpDirectiveName -> llvm::omp::Directive = taskgraph | 
|  | 72 | +!PARSE-TREE: | | OmpClauseList -> | 
|  | 73 | +!PARSE-TREE: | | Flags = None | 
|  | 74 | + | 
|  | 75 | + | 
|  | 76 | +subroutine f02 | 
|  | 77 | +  !$omp taskgraph graph_reset | 
|  | 78 | +  !$omp end taskgraph | 
|  | 79 | +end | 
|  | 80 | + | 
|  | 81 | +!UNPARSE: SUBROUTINE f02 | 
|  | 82 | +!UNPARSE: !$OMP TASKGRAPH GRAPH_RESET | 
|  | 83 | +!UNPARSE: !$OMP END TASKGRAPH | 
|  | 84 | +!UNPARSE: END SUBROUTINE | 
|  | 85 | + | 
|  | 86 | +!PARSE-TREE: ExecutionPartConstruct -> ExecutableConstruct -> OpenMPConstruct -> OmpBlockConstruct | 
|  | 87 | +!PARSE-TREE: | OmpBeginDirective | 
|  | 88 | +!PARSE-TREE: | | OmpDirectiveName -> llvm::omp::Directive = taskgraph | 
|  | 89 | +!PARSE-TREE: | | OmpClauseList -> OmpClause -> GraphReset -> | 
|  | 90 | +!PARSE-TREE: | | Flags = None | 
|  | 91 | +!PARSE-TREE: | Block | 
|  | 92 | +!PARSE-TREE: | OmpEndDirective | 
|  | 93 | +!PARSE-TREE: | | OmpDirectiveName -> llvm::omp::Directive = taskgraph | 
|  | 94 | +!PARSE-TREE: | | OmpClauseList -> | 
|  | 95 | +!PARSE-TREE: | | Flags = None | 
0 commit comments