Author: erichkeane Date: 2024-11-13T06:54:25-08:00 New Revision: a86d00cf24008929bf32393415bf532c59cec4c4
URL: https://github.com/llvm/llvm-project/commit/a86d00cf24008929bf32393415bf532c59cec4c4 DIFF: https://github.com/llvm/llvm-project/commit/a86d00cf24008929bf32393415bf532c59cec4c4.diff LOG: [OpenACC] Implement combined constr 'seq'/'independent'/'auto' clauses These three are identical to the version on compute constructs, so this patch implements the tests for it, and ensures that we properly validate it against all the other clauses we're supposed to. The test is mostly a mock-up at the moment, since most other clauses aren't implemented yet for 'loop'. Added: clang/test/SemaOpenACC/combined-construct-auto_seq_independent-ast.cpp clang/test/SemaOpenACC/combined-construct-auto_seq_independent-clauses.c Modified: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Sema/SemaOpenACC.cpp clang/test/ParserOpenACC/parse-clauses.c clang/test/SemaOpenACC/combined-construct.cpp Removed: ################################################################################ diff --git a/clang/include/clang/Basic/DiagnosticSemaKinds.td b/clang/include/clang/Basic/DiagnosticSemaKinds.td index 36c89c8fdc9ece..dc9f36c308db91 100644 --- a/clang/include/clang/Basic/DiagnosticSemaKinds.td +++ b/clang/include/clang/Basic/DiagnosticSemaKinds.td @@ -12689,7 +12689,7 @@ def err_acc_clause_after_device_type "%select{'%3'|compute}2 construct">; def err_acc_clause_cannot_combine : Error<"OpenACC clause '%0' may not appear on the same construct as a " - "'%1' clause on a 'loop' construct">; + "'%1' clause on a '%2' construct">; def err_acc_reduction_num_gangs_conflict : Error< "OpenACC 'reduction' clause may not appear on a 'parallel' construct " diff --git a/clang/lib/Sema/SemaOpenACC.cpp b/clang/lib/Sema/SemaOpenACC.cpp index fc0efa457df99c..d33c84de21709c 100644 --- a/clang/lib/Sema/SemaOpenACC.cpp +++ b/clang/lib/Sema/SemaOpenACC.cpp @@ -479,6 +479,26 @@ bool checkValidAfterDeviceType( default: break; } + } else if (isOpenACCCombinedDirectiveKind(NewClause.getDirectiveKind())) { + // This seems like it should be the union of 2.9 and 2.5.4 from above. + switch (NewClause.getClauseKind()) { + case OpenACCClauseKind::Async: + case OpenACCClauseKind::Wait: + case OpenACCClauseKind::NumGangs: + case OpenACCClauseKind::NumWorkers: + case OpenACCClauseKind::VectorLength: + case OpenACCClauseKind::Collapse: + case OpenACCClauseKind::Gang: + case OpenACCClauseKind::Worker: + case OpenACCClauseKind::Vector: + case OpenACCClauseKind::Seq: + case OpenACCClauseKind::Independent: + case OpenACCClauseKind::Auto: + case OpenACCClauseKind::Tile: + return false; + default: + break; + } } S.Diag(NewClause.getBeginLoc(), diag::err_acc_clause_after_device_type) << NewClause.getClauseKind() << DeviceTypeClause.getClauseKind() @@ -508,7 +528,8 @@ class SemaOpenACCClauseVisitor { if (Itr != ExistingClauses.end()) { SemaRef.Diag(Clause.getBeginLoc(), diag::err_acc_clause_cannot_combine) - << Clause.getClauseKind() << (*Itr)->getClauseKind(); + << Clause.getClauseKind() << (*Itr)->getClauseKind() + << Clause.getDirectiveKind(); SemaRef.Diag((*Itr)->getBeginLoc(), diag::note_acc_previous_clause_here); return true; @@ -997,12 +1018,6 @@ OpenACCClause *SemaOpenACCClauseVisitor::VisitDeviceTypeClause( OpenACCClause *SemaOpenACCClauseVisitor::VisitAutoClause( SemaOpenACC::OpenACCParsedClause &Clause) { - // Restrictions only properly implemented on 'loop' constructs, and it is - // the only construct that can do anything with this, so skip/treat as - // unimplemented for the combined constructs. - if (Clause.getDirectiveKind() != OpenACCDirectiveKind::Loop) - return isNotImplemented(); - // OpenACC 3.3 2.9: // Only one of the seq, independent, and auto clauses may appear. const auto *Itr = @@ -1021,12 +1036,6 @@ OpenACCClause *SemaOpenACCClauseVisitor::VisitAutoClause( OpenACCClause *SemaOpenACCClauseVisitor::VisitIndependentClause( SemaOpenACC::OpenACCParsedClause &Clause) { - // Restrictions only properly implemented on 'loop' constructs, and it is - // the only construct that can do anything with this, so skip/treat as - // unimplemented for the combined constructs. - if (Clause.getDirectiveKind() != OpenACCDirectiveKind::Loop) - return isNotImplemented(); - // OpenACC 3.3 2.9: // Only one of the seq, independent, and auto clauses may appear. const auto *Itr = llvm::find_if( @@ -1356,10 +1365,10 @@ OpenACCClause *SemaOpenACCClauseVisitor::VisitGangClause( OpenACCClause *SemaOpenACCClauseVisitor::VisitSeqClause( SemaOpenACC::OpenACCParsedClause &Clause) { - // Restrictions only properly implemented on 'loop' constructs, and it is - // the only construct that can do anything with this, so skip/treat as - // unimplemented for the combined constructs. - if (Clause.getDirectiveKind() != OpenACCDirectiveKind::Loop) + // Restrictions only properly implemented on 'loop' constructs and combined , + // and it is the only construct that can do anything with this, so skip/treat + // as unimplemented for the routine constructs. + if (Clause.getDirectiveKind() == OpenACCDirectiveKind::Routine) return isNotImplemented(); // OpenACC 3.3 2.9: @@ -1383,14 +1392,12 @@ OpenACCClause *SemaOpenACCClauseVisitor::VisitSeqClause( if (Itr != ExistingClauses.end()) { SemaRef.Diag(Clause.getBeginLoc(), diag::err_acc_clause_cannot_combine) - << Clause.getClauseKind() << (*Itr)->getClauseKind(); + << Clause.getClauseKind() << (*Itr)->getClauseKind() + << Clause.getDirectiveKind(); SemaRef.Diag((*Itr)->getBeginLoc(), diag::note_acc_previous_clause_here); return nullptr; } - // TODO OpenACC: 2.9 ~ line 2010 specifies that the associated loop has some - // restrictions when there is a 'seq' clause in place. We probably need to - // implement that. return OpenACCSeqClause::Create(Ctx, Clause.getBeginLoc(), Clause.getEndLoc()); } @@ -1490,6 +1497,9 @@ OpenACCClause *SemaOpenACCClauseVisitor::VisitReductionClause( OpenACCClause *SemaOpenACCClauseVisitor::VisitCollapseClause( SemaOpenACC::OpenACCParsedClause &Clause) { + if (!isOpenACCComputeDirectiveKind(Clause.getDirectiveKind()) && + Clause.getDirectiveKind() != OpenACCDirectiveKind::Loop) + return isNotImplemented(); // Duplicates here are not really sensible. We could possible permit // multiples if they all had the same value, but there isn't really a good // reason to do so. Also, this simplifies the suppression of duplicates, in diff --git a/clang/test/ParserOpenACC/parse-clauses.c b/clang/test/ParserOpenACC/parse-clauses.c index 1ebae16f69458a..a0e01ef5a85a62 100644 --- a/clang/test/ParserOpenACC/parse-clauses.c +++ b/clang/test/ParserOpenACC/parse-clauses.c @@ -58,21 +58,21 @@ void func() { #pragma acc loop seq independent, auto for(int i = 0; i < 5;++i) {} - // expected-warning@+3{{OpenACC clause 'seq' not yet implemented, clause ignored}} - // expected-warning@+2{{OpenACC clause 'independent' not yet implemented, clause ignored}} - // expected-warning@+1{{OpenACC clause 'auto' not yet implemented, clause ignored}} + // expected-error@+3{{OpenACC clause 'independent' on 'kernels loop' construct conflicts with previous data dependence clause}} + // expected-error@+2{{OpenACC clause 'auto' on 'kernels loop' construct conflicts with previous data dependence clause}} + // expected-note@+1 2{{previous clause is here}} #pragma acc kernels loop seq independent auto for(int i = 0; i < 5;++i) {} - // expected-warning@+3{{OpenACC clause 'seq' not yet implemented, clause ignored}} - // expected-warning@+2{{OpenACC clause 'independent' not yet implemented, clause ignored}} - // expected-warning@+1{{OpenACC clause 'auto' not yet implemented, clause ignored}} + // expected-error@+3{{OpenACC clause 'independent' on 'serial loop' construct conflicts with previous data dependence clause}} + // expected-error@+2{{OpenACC clause 'auto' on 'serial loop' construct conflicts with previous data dependence clause}} + // expected-note@+1 2{{previous clause is here}} #pragma acc serial loop seq, independent auto for(int i = 0; i < 5;++i) {} - // expected-warning@+3{{OpenACC clause 'seq' not yet implemented, clause ignored}} - // expected-warning@+2{{OpenACC clause 'independent' not yet implemented, clause ignored}} - // expected-warning@+1{{OpenACC clause 'auto' not yet implemented, clause ignored}} + // expected-error@+3{{OpenACC clause 'independent' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-error@+2{{OpenACC clause 'auto' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1 2{{previous clause is here}} #pragma acc parallel loop seq independent, auto for(int i = 0; i < 5;++i) {} @@ -270,8 +270,7 @@ void SelfClause() { #pragma acc serial loop self for(int i = 0; i < 5;++i) {} - // expected-warning@+2{{OpenACC clause 'self' not yet implemented, clause ignored}} - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented, clause ignored}} #pragma acc serial loop self, seq for(int i = 0; i < 5;++i) {} @@ -310,19 +309,16 @@ void SelfClause() { for(int i = 0; i < 5;++i) {} - // expected-error@+2{{expected expression}} - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} + // expected-error@+1{{expected expression}} #pragma acc serial loop self(), seq for(int i = 0; i < 5;++i) {} - // expected-error@+3{{expected expression}} // expected-error@+2{{expected expression}} - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} + // expected-error@+1{{expected expression}} #pragma acc serial loop self(,), seq for(int i = 0; i < 5;++i) {} - // expected-error@+2{{use of undeclared identifier 'invalid_expr'}} - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} + // expected-error@+1{{use of undeclared identifier 'invalid_expr'}} #pragma acc serial loop self(invalid_expr), seq for(int i = 0; i < 5;++i) {} diff --git a/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-ast.cpp b/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-ast.cpp new file mode 100644 index 00000000000000..cc641fdff32d63 --- /dev/null +++ b/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-ast.cpp @@ -0,0 +1,160 @@ +// RUN: %clang_cc1 %s -fopenacc -ast-dump | FileCheck %s + +// Test this with PCH. +// RUN: %clang_cc1 %s -fopenacc -emit-pch -o %t %s +// RUN: %clang_cc1 %s -fopenacc -include-pch %t -ast-dump-all | FileCheck %s +#ifndef PCH_HELPER +#define PCH_HELPER + +void NormalUses() { + // CHECK: FunctionDecl{{.*}}NormalUses + // CHECK-NEXT: CompoundStmt + +#pragma acc parallel loop auto + for(int i = 0; i < 5; ++i){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} parallel loop + // CHECK-NEXT: auto clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt + +#pragma acc serial loop seq + for(;;){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} serial loop + // CHECK-NEXT: seq clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: CompoundStmt + +#pragma acc kernels loop independent + for(int i = 0; i < 5; ++i){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} kernels loop + // CHECK-NEXT: independent clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt +} + +template<typename T> +void TemplUses() { + // CHECK: FunctionTemplateDecl{{.*}}TemplUses + // CHECK-NEXT: TemplateTypeParmDecl + // CHECK-NEXT: FunctionDecl{{.*}} TemplUses + // CHECK-NEXT: CompoundStmt + +#pragma acc parallel loop auto + for(int i = 0; i < 5; ++i){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} parallel loop + // CHECK-NEXT: auto clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt + +#pragma acc serial loop seq + for(;;){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} serial loop + // CHECK-NEXT: seq clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: CompoundStmt + +#pragma acc kernels loop independent + for(int i = 0; i < 5; ++i){} + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} kernels loop + // CHECK-NEXT: independent clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt + + // Instantiations. + // CHECK-NEXT: FunctionDecl{{.*}}TemplUses 'void ()' implicit_instantiation + // CHECK-NEXT: TemplateArgument + // CHECK-NEXT: BuiltinType + // CHECK-NEXT: CompoundStmt + + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} parallel loop + // CHECK-NEXT: auto clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt + + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} serial loop + // CHECK-NEXT: seq clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: CompoundStmt + + // CHECK-NEXT: OpenACCCombinedConstruct{{.*}} kernels loop + // CHECK-NEXT: independent clause + // CHECK-NEXT: ForStmt + // CHECK-NEXT: DeclStmt + // CHECK-NEXT: VarDecl{{.*}} i 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 0 + // CHECK-NEXT: <<<NULL>>> + // CHECK-NEXT: BinaryOperator{{.*}}'<' + // CHECK-NEXT: ImplicitCastExpr + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: IntegerLiteral{{.*}} 'int' 5 + // CHECK-NEXT: UnaryOperator{{.*}}++ + // CHECK-NEXT: DeclRefExpr{{.*}}'i' 'int' + // CHECK-NEXT: CompoundStmt +} + +void Inst() { + TemplUses<int>(); +} +#endif // PCH_HELPER diff --git a/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-clauses.c b/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-clauses.c new file mode 100644 index 00000000000000..d776882b768448 --- /dev/null +++ b/clang/test/SemaOpenACC/combined-construct-auto_seq_independent-clauses.c @@ -0,0 +1,1110 @@ + +// RUN: %clang_cc1 %s -fopenacc -verify + +// TODO: OpenACC: A number of the 'not yet implemented' diagnostics interfere +// with the diagnostics we want to make here, so as we implement these, we need +// to replace the errors we should have. +void uses() { +#pragma acc parallel loop auto + for(unsigned i = 0; i < 5; ++i); +#pragma acc parallel loop seq + for(unsigned i = 0; i < 5; ++i); +#pragma acc parallel loop independent + for(unsigned i = 0; i < 5; ++i); + + // expected-error@+2{{OpenACC clause 'seq' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop auto seq + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'independent' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop auto independent + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'auto' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop seq auto + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'independent' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop seq independent + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'auto' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop independent auto + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'seq' on 'parallel loop' construct conflicts with previous data dependence clause}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop independent seq + for(unsigned i = 0; i < 5; ++i); + + int Var; + int *VarPtr; + + // 'auto' can combine with any other clause. + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop auto finalize + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop auto if_present + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'worker' not yet implemented}} +#pragma acc parallel loop auto worker + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'vector' not yet implemented}} +#pragma acc parallel loop auto vector + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop auto nohost + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC clause 'default' not yet implemented, clause ignored}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop auto default(none) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop auto if(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop auto self + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop auto copy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop auto pcopy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop auto present_or_copy(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop auto use_device(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop auto attach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop auto delete(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop auto detach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop auto device(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop auto deviceptr(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop auto device_resident(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop auto firstprivate(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop auto host(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop auto link(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop auto no_create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop auto present(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop auto private(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop auto copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop auto pcopyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop auto present_or_copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop auto copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop auto pcopyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop auto present_or_copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop auto create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop auto pcreate(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop auto present_or_create(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop auto reduction(+:Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop auto collapse(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop auto bind(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop auto vector_length(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop auto num_gangs(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop auto num_workers(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop auto device_num(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop auto default_async(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop auto device_type(*) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop auto dtype(*) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop auto async + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop auto tile(1+2, 1) + for(unsigned j = 0; j < 5; ++j) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'gang' not yet implemented}} +#pragma acc parallel loop auto gang + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop auto wait + for(unsigned i = 0; i < 5; ++i); + + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop finalize auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop if_present auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'worker' not yet implemented}} +#pragma acc parallel loop worker auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'vector' not yet implemented}} +#pragma acc parallel loop vector auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop nohost auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'default' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop default(none) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop if(1) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop self auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop copy(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop pcopy(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop present_or_copy(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop use_device(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop attach(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop delete(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop detach(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop device(VarPtr) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop deviceptr(VarPtr) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop device_resident(VarPtr) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop firstprivate(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop host(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop link(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop no_create(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop present(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop private(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop copyout(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop pcopyout(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop present_or_copyout(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop copyin(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop pcopyin(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop present_or_copyin(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop create(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop pcreate(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop present_or_create(Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop reduction(+:Var) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop collapse(1) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop bind(Var) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop vector_length(1) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop num_gangs(1) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop num_workers(1) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop device_num(1) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop default_async(1) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop device_type(*) auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop dtype(*) auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop async auto + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop tile(1+2, 1) auto + for(unsigned j = 0; j < 5; ++j) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'gang' not yet implemented}} +#pragma acc parallel loop gang auto + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop wait auto + for(unsigned i = 0; i < 5; ++i); + + // 'independent' can also be combined with any clauses + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop independent finalize + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop independent if_present + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'worker' not yet implemented}} +#pragma acc parallel loop independent worker + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'vector' not yet implemented}} +#pragma acc parallel loop independent vector + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop independent nohost + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'default' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop independent default(none) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop independent if(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop independent self + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop independent copy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop independent pcopy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop independent present_or_copy(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop independent use_device(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop independent attach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop independent delete(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop independent detach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop independent device(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop independent deviceptr(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop independent device_resident(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop independent firstprivate(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop independent host(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop independent link(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop independent no_create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop independent present(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop independent private(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop independent copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop independent pcopyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop independent present_or_copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop independent copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop independent pcopyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop independent present_or_copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop independent create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop independent pcreate(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop independent present_or_create(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop independent reduction(+:Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop independent collapse(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop independent bind(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop independent vector_length(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop independent num_gangs(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop independent num_workers(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop independent device_num(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop independent default_async(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop independent device_type(*) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop independent dtype(*) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop independent async + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop independent tile(1+2, 1) + for(unsigned j = 0; j < 5; ++j) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'gang' not yet implemented}} +#pragma acc parallel loop independent gang + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop independent wait + for(unsigned i = 0; i < 5; ++i); + + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop finalize independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop if_present independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'worker' not yet implemented}} +#pragma acc parallel loop worker independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'vector' not yet implemented}} +#pragma acc parallel loop vector independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop nohost independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'default' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop default(none) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop if(1) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop self independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop copy(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop pcopy(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop present_or_copy(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop use_device(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop attach(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop delete(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop detach(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop device(VarPtr) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop deviceptr(VarPtr) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop device_resident(VarPtr) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop firstprivate(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop host(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop link(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop no_create(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop present(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop private(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop copyout(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TDOOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop pcopyout(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop present_or_copyout(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TDOOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop copyin(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop pcopyin(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop present_or_copyin(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop create(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop pcreate(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop present_or_create(Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop reduction(+:Var) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop collapse(1) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop bind(Var) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop vector_length(1) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop num_gangs(1) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop num_workers(1) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop device_num(1) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop default_async(1) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop device_type(*) independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop dtype(*) independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop async independent + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop tile(1+2, 1) independent + for(unsigned j = 0; j < 5; ++j) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'gang' not yet implemented}} +#pragma acc parallel loop gang independent + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop wait independent + for(unsigned i = 0; i < 5; ++i); + + // 'seq' cannot be combined with 'gang', 'worker' or 'vector' + // expected-error@+2{{OpenACC clause 'gang' may not appear on the same construct as a 'seq' clause on a 'parallel loop' construct}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop seq gang + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'worker' may not appear on the same construct as a 'seq' clause on a 'parallel loop' construct}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop seq worker + for(unsigned i = 0; i < 5; ++i); + // expected-error@+2{{OpenACC clause 'vector' may not appear on the same construct as a 'seq' clause on a 'parallel loop' construct}} + // expected-note@+1{{previous clause is here}} +#pragma acc parallel loop seq vector + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop seq finalize + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop seq if_present + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop seq nohost + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'default' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop seq default(none) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop seq if(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop seq self + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop seq copy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop seq pcopy(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop seq present_or_copy(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop seq use_device(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop seq attach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop seq delete(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop seq detach(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop seq device(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop seq deviceptr(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop seq device_resident(VarPtr) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop seq firstprivate(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop seq host(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop seq link(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop seq no_create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop seq present(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop seq private(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop seq copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop seq pcopyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop seq present_or_copyout(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop seq copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop seq pcopyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop seq present_or_copyin(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop seq create(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop seq pcreate(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop seq present_or_create(Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop seq reduction(+:Var) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop seq collapse(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop seq bind(Var) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop seq vector_length(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop seq num_gangs(1) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop seq num_workers(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop seq device_num(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop seq default_async(1) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop seq device_type(*) + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop seq dtype(*) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop seq async + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop seq tile(1+2, 1) + for(;;) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop seq wait + for(unsigned i = 0; i < 5; ++i); + + // TODOexpected-error@+2{{OpenACC clause 'seq' may not appear on the same construct as a 'gang' clause on a 'parallel loop' construct}} + // TODOexpected-note@+1{{previous clause is here}} + // expected-warning@+1{{OpenACC clause 'gang' not yet implemented}} +#pragma acc parallel loop gang seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+2{{OpenACC clause 'seq' may not appear on the same construct as a 'worker' clause on a 'parallel loop' construct}} + // TODOexpected-note@+1{{previous clause is here}} + // expected-warning@+1{{OpenACC clause 'worker' not yet implemented}} +#pragma acc parallel loop worker seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+2{{OpenACC clause 'seq' may not appear on the same construct as a 'vector' clause on a 'parallel loop' construct}} + // TODOexpected-note@+1{{previous clause is here}} + // expected-warning@+1{{OpenACC clause 'vector' not yet implemented}} +#pragma acc parallel loop vector seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'finalize' not yet implemented}} +#pragma acc parallel loop finalize seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'if_present' not yet implemented}} +#pragma acc parallel loop if_present seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'nohost' not yet implemented}} +#pragma acc parallel loop nohost seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'default' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'default' not yet implemented}} +#pragma acc parallel loop default(none) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'if' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'if' not yet implemented}} +#pragma acc parallel loop if(1) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'self' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'self' not yet implemented}} +#pragma acc parallel loop self seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copy' not yet implemented}} +#pragma acc parallel loop copy(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'pcopy' not yet implemented}} +#pragma acc parallel loop pcopy(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copy' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copy' is a deprecated clause name and is now an alias for 'copy'}} + // expected-warning@+1{{OpenACC clause 'present_or_copy' not yet implemented}} +#pragma acc parallel loop present_or_copy(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'use_device' not yet implemented}} +#pragma acc parallel loop use_device(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'attach' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'attach' not yet implemented}} +#pragma acc parallel loop attach(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'delete' not yet implemented}} +#pragma acc parallel loop delete(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'detach' not yet implemented}} +#pragma acc parallel loop detach(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device' not yet implemented}} +#pragma acc parallel loop device(VarPtr) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'deviceptr' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'deviceptr' not yet implemented}} +#pragma acc parallel loop deviceptr(VarPtr) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_resident' not yet implemented}} +#pragma acc parallel loop device_resident(VarPtr) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'firstprivate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'firstprivate' not yet implemented}} +#pragma acc parallel loop firstprivate(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'host' not yet implemented}} +#pragma acc parallel loop host(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'link' not yet implemented}} +#pragma acc parallel loop link(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'no_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'no_create' not yet implemented}} +#pragma acc parallel loop no_create(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'present' not yet implemented}} +#pragma acc parallel loop present(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'private' not yet implemented}} +#pragma acc parallel loop private(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyout' not yet implemented}} +#pragma acc parallel loop copyout(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'pcopyout' not yet implemented}} +#pragma acc parallel loop pcopyout(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyout' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyout' is a deprecated clause name and is now an alias for 'copyout'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyout' not yet implemented}} +#pragma acc parallel loop present_or_copyout(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'copyin' not yet implemented}} +#pragma acc parallel loop copyin(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcopyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcopyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'pcopyin' not yet implemented}} +#pragma acc parallel loop pcopyin(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_copyin' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_copyin' is a deprecated clause name and is now an alias for 'copyin'}} + // expected-warning@+1{{OpenACC clause 'present_or_copyin' not yet implemented}} +#pragma acc parallel loop present_or_copyin(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'create' not yet implemented}} +#pragma acc parallel loop create(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'pcreate' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'pcreate' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'pcreate' not yet implemented}} +#pragma acc parallel loop pcreate(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'present_or_create' clause is not valid on 'parallel loop' directive}} + // expected-warning@+2{{OpenACC clause name 'present_or_create' is a deprecated clause name and is now an alias for 'create'}} + // expected-warning@+1{{OpenACC clause 'present_or_create' not yet implemented}} +#pragma acc parallel loop present_or_create(Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'reduction' not yet implemented}} +#pragma acc parallel loop reduction(+:Var) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'collapse' not yet implemented}} +#pragma acc parallel loop collapse(1) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'bind' not yet implemented}} +#pragma acc parallel loop bind(Var) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'vector_length' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'vector_length' not yet implemented}} +#pragma acc parallel loop vector_length(1) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_gangs' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_gangs' not yet implemented}} +#pragma acc parallel loop num_gangs(1) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'num_workers' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'num_workers' not yet implemented}} +#pragma acc parallel loop num_workers(1) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_num' not yet implemented}} +#pragma acc parallel loop device_num(1) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'default_async' not yet implemented}} +#pragma acc parallel loop default_async(1) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'device_type' not yet implemented}} +#pragma acc parallel loop device_type(*) seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'dtype' not yet implemented}} +#pragma acc parallel loop dtype(*) seq + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'async' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'async' not yet implemented}} +#pragma acc parallel loop async seq + for(unsigned i = 0; i < 5; ++i); + // expected-warning@+1{{OpenACC clause 'tile' not yet implemented}} +#pragma acc parallel loop tile(1+2, 1) seq + for(;;) + for(unsigned i = 0; i < 5; ++i); + // TODOexpected-error@+1{{OpenACC 'wait' clause is not valid on 'parallel loop' directive}} + // expected-warning@+1{{OpenACC clause 'wait' not yet implemented}} +#pragma acc parallel loop wait seq + for(unsigned i = 0; i < 5; ++i); +} diff --git a/clang/test/SemaOpenACC/combined-construct.cpp b/clang/test/SemaOpenACC/combined-construct.cpp index ffa67b80bef9f8..75fcbbd851f4aa 100644 --- a/clang/test/SemaOpenACC/combined-construct.cpp +++ b/clang/test/SemaOpenACC/combined-construct.cpp @@ -46,228 +46,97 @@ void func_call(); template<typename Int, typename IntPtr, typename Float, typename Struct, typename Iterator, typename RandAccessIterator> void SeqLoopRules() { - // expected-warning@+3{{OpenACC clause 'seq' not yet implemented, clause ignored}} // expected-error@+3{{OpenACC 'parallel loop' construct can only be applied to a 'for' loop}} // expected-note@+1{{'parallel loop' construct is here}} #pragma acc parallel loop seq while(true); // No rules in this section! - // TODO: OpenACC: When we implement 'seq' for the combined constructs, all of - // these diagnostics here should go away. - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+6{{OpenACC 'kernels loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'kernels loop' construct is here}} - // expected-error@+4{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-4{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'kernels loop' construct is here}} for(;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+6{{loop variable of loop associated with an OpenACC 'parallel loop' construct must be of integer, pointer, or random-access-iterator type (is 'float')}} - // expected-note@-2{{'parallel loop' construct is here}} - // expected-error@+4{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-4{{'parallel loop' construct is here}} - // expected-error@+2{{OpenACC 'parallel loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'parallel loop' construct is here}} for(float f = 0;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+6{{OpenACC 'serial loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'serial loop' construct is here}} - // expected-error@+4{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-4{{'serial loop' construct is here}} - // expected-error@+2{{OpenACC 'serial loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'serial loop' construct is here}} for(int f;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+6 2{{OpenACC 'kernels loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2 2{{'kernels loop' construct is here}} - // expected-error@+4{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-4{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'kernels loop' construct is here}} for(int f,g;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+4{{OpenACC 'parallel loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'parallel loop' construct is here}} - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-4{{'parallel loop' construct is here}} for(Int f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+2{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-2{{'serial loop' construct is here}} for(Int *f = nullptr;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+2{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-2{{'kernels loop' construct is here}} for(IntPtr f = nullptr;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-2{{'parallel loop' construct is here}} for(Float *f = nullptr;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+6{{loop variable of loop associated with an OpenACC 'serial loop' construct must be of integer, pointer, or random-access-iterator type (is 'SomeStruct')}} - // expected-note@-2{{'serial loop' construct is here}} - // expected-error@+4{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-4{{'serial loop' construct is here}} - // expected-error@+2{{OpenACC 'serial loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'serial loop' construct is here}} for(SomeStruct f;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+4{{loop variable of loop associated with an OpenACC 'kernels loop' construct must be of integer, pointer, or random-access-iterator type (is 'SomeStruct')}} - // expected-note@-2{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-4{{'kernels loop' construct is here}} for(Struct f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+4{{loop variable of loop associated with an OpenACC 'parallel loop' construct must be of integer, pointer, or random-access-iterator type (is 'SomeIterator')}} - // expected-note@-2{{'parallel loop' construct is here}} - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-4{{'parallel loop' construct is here}} for(SomeIterator f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+4{{loop variable of loop associated with an OpenACC 'serial loop' construct must be of integer, pointer, or random-access-iterator type (is 'SomeIterator')}} - // expected-note@-2{{'serial loop' construct is here}} - // expected-error@+2{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-4{{'serial loop' construct is here}} for(Iterator f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+2{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-2{{'kernels loop' construct is here}} for(SomeRAIterator f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-2{{'parallel loop' construct is here}} for(RandAccessIterator f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+6{{OpenACC 'kernels loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'kernels loop' construct is here}} - // expected-error@+4{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-4{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'kernels loop' construct is here}} for(Int f;;); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+4{{OpenACC 'parallel loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'parallel loop' construct is here}} - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-4{{'parallel loop' construct is here}} for(Int f;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+4{{OpenACC 'serial loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'serial loop' construct is here}} - // expected-error@+2{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-4{{'serial loop' construct is here}} for(Int f;;f+=1); int i; - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+6{{OpenACC 'kernels loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'kernels loop' construct is here}} - // expected-error@+4{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-4{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'kernels loop' construct is here}} for(Int f;;i+=1); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+6{{OpenACC 'parallel loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2{{'parallel loop' construct is here}} - // expected-error@+4{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-4{{'parallel loop' construct is here}} - // expected-error@+2{{OpenACC 'parallel loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-6{{'parallel loop' construct is here}} for(Int f;;i++); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+4{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-2{{'serial loop' construct is here}} - // expected-error@+2{{OpenACC 'serial loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-4{{'serial loop' construct is here}} for(RandAccessIterator f;;i++); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+4{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-2{{'kernels loop' construct is here}} - // expected-error@+2{{OpenACC 'kernels loop' variable must monotonically increase or decrease ('++', '--', or compound assignment)}} - // expected-note@-4{{'kernels loop' construct is here}} for(RandAccessIterator f;;func_call()); Int Array[5]; - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq for(auto X : Array); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+2 2{{loop variable of loop associated with an OpenACC 'serial loop' construct must be of integer, pointer, or random-access-iterator type (is 'SomeIterator')}} - // expected-note@-2 2{{'serial loop' construct is here}} for(auto X : HasIteratorCollection{}); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq for(auto X : HasRAIteratorCollection{}); RandAccessIterator f, end; - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+2 2{{OpenACC 'parallel loop' construct must have initialization clause in canonical form ('var = init' or 'T var = init'}} - // expected-note@-2 2{{'parallel loop' construct is here}} for(f;f != end;f++); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc kernels loop seq - // expected-error@+2{{OpenACC 'kernels loop' construct must have a terminating condition}} - // expected-note@-2{{'kernels loop' construct is here}} for(f = 0;;++f); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc parallel loop seq - // expected-error@+2{{OpenACC 'parallel loop' construct must have a terminating condition}} - // expected-note@-2{{'parallel loop' construct is here}} for(f = 0;;f++); - // expected-warning@+1{{OpenACC clause 'seq' not yet implemented, clause ignored}} #pragma acc serial loop seq - // expected-error@+2{{OpenACC 'serial loop' construct must have a terminating condition}} - // expected-note@-2{{'serial loop' construct is here}} for(f = 0;;f+=1); } @@ -517,7 +386,6 @@ void LoopRules() { } void inst() { - // expected-note@+1{{in instantiation of function template specialization}} SeqLoopRules<int, int*, float, SomeStruct, SomeIterator, SomeRAIterator>(); // expected-note@+1{{in instantiation of function template specialization}} LoopRules<int, int*, float, SomeStruct, SomeIterator, SomeRAIterator>(); _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits