55 lines · plain
1!RUN: %flang_fc1 -fdebug-unparse -fopenmp -fopenmp-version=52 %s | FileCheck --ignore-case --check-prefix="UNPARSE" %s2!RUN: %flang_fc1 -fdebug-dump-parse-tree -fopenmp -fopenmp-version=52 %s | FileCheck --check-prefix="PARSE-TREE" %s3 4subroutine f00()5 integer :: x6 !$omp metadirective when(user={condition(.true.)}: flush seq_cst (x))7end8 9!UNPARSE: SUBROUTINE f0010!UNPARSE: INTEGER x11!UNPARSE: !$OMP METADIRECTIVE WHEN(USER={CONDITION(.true._4)}: FLUSH SEQ_CST(x))12!UNPARSE: END SUBROUTINE13 14!PARSE-TREE: OmpMetadirectiveDirective15!PARSE-TREE: | OmpClauseList -> OmpClause -> When -> OmpWhenClause16!PARSE-TREE: | | Modifier -> OmpContextSelectorSpecification -> OmpTraitSetSelector17!PARSE-TREE: | | | OmpTraitSetSelectorName -> Value = User18!PARSE-TREE: | | | OmpTraitSelector19!PARSE-TREE: | | | | OmpTraitSelectorName -> Value = Condition20!PARSE-TREE: | | | | Properties21!PARSE-TREE: | | | | | OmpTraitProperty -> Scalar -> Expr = '.true._4'22!PARSE-TREE: | | | | | | LiteralConstant -> LogicalLiteralConstant23!PARSE-TREE: | | | | | | | bool = 'true'24!PARSE-TREE: | | OmpDirectiveSpecification25!PARSE-TREE: | | | OmpDirectiveName -> llvm::omp::Directive = flush26!PARSE-TREE: | | | OmpArgumentList -> OmpArgument -> OmpLocator -> OmpObject -> Designator -> DataRef -> Name = 'x'27!PARSE-TREE: | | | OmpClauseList -> OmpClause -> SeqCst28!PARSE-TREE: | | | Flags = {DeprecatedSyntax}29 30subroutine f01()31 integer :: x32 !$omp metadirective when(user={condition(.true.)}: flush(x) seq_cst)33end34 35!UNPARSE: SUBROUTINE f0136!UNPARSE: INTEGER x37!UNPARSE: !$OMP METADIRECTIVE WHEN(USER={CONDITION(.true._4)}: FLUSH(x) SEQ_CST)38!UNPARSE: END SUBROUTINE39 40!PARSE-TREE: OmpMetadirectiveDirective41!PARSE-TREE: | OmpClauseList -> OmpClause -> When -> OmpWhenClause42!PARSE-TREE: | | Modifier -> OmpContextSelectorSpecification -> OmpTraitSetSelector43!PARSE-TREE: | | | OmpTraitSetSelectorName -> Value = User44!PARSE-TREE: | | | OmpTraitSelector45!PARSE-TREE: | | | | OmpTraitSelectorName -> Value = Condition46!PARSE-TREE: | | | | Properties47!PARSE-TREE: | | | | | OmpTraitProperty -> Scalar -> Expr = '.true._4'48!PARSE-TREE: | | | | | | LiteralConstant -> LogicalLiteralConstant49!PARSE-TREE: | | | | | | | bool = 'true'50!PARSE-TREE: | | OmpDirectiveSpecification51!PARSE-TREE: | | | OmpDirectiveName -> llvm::omp::Directive = flush52!PARSE-TREE: | | | OmpArgumentList -> OmpArgument -> OmpLocator -> OmpObject -> Designator -> DataRef -> Name = 'x'53!PARSE-TREE: | | | OmpClauseList -> OmpClause -> SeqCst54!PARSE-TREE: | | | Flags = {}55