forked from OSchip/llvm-project
[flang] [OpenMP] update `declare simd` directive with exclusive set
Original-commit: flang-compiler/f18@dc1bd8edc6
This commit is contained in:
parent
e902c1d6b7
commit
d1bbccf1d5
|
@ -416,10 +416,11 @@ void OmpStructureChecker::Enter(const parser::OpenMPDeclareSimdConstruct &x) {
|
|||
// uniform-clause |
|
||||
// inbranch-clause |
|
||||
// notinbranch-clause
|
||||
OmpClauseSet allowed{OmpClause::LINEAR, OmpClause::ALIGNED,
|
||||
OmpClause::UNIFORM, OmpClause::INBRANCH, OmpClause::NOTINBRANCH};
|
||||
OmpClauseSet allowed{
|
||||
OmpClause::LINEAR, OmpClause::ALIGNED, OmpClause::UNIFORM};
|
||||
SetContextAllowed(allowed);
|
||||
SetContextAllowedOnce({OmpClause::SIMDLEN});
|
||||
SetContextAllowedExclusive({OmpClause::INBRANCH, OmpClause::NOTINBRANCH});
|
||||
}
|
||||
|
||||
void OmpStructureChecker::Leave(const parser::OpenMPDeclareSimdConstruct &) {
|
||||
|
|
|
@ -42,7 +42,8 @@ subroutine declare_simd_2
|
|||
use m1
|
||||
procedure (sub) sub1
|
||||
!ERROR: Internal: no symbol found for 'sub1'
|
||||
!$omp declare simd(sub1)
|
||||
!ERROR: NOTINBRANCH and INBRANCH are mutually exclusive and may not appear on the same DECLARE SIMD directive
|
||||
!$omp declare simd(sub1) inbranch notinbranch
|
||||
procedure (sub), pointer::p
|
||||
p=>sub1
|
||||
call p(5,10)
|
||||
|
|
Loading…
Reference in New Issue