Lines Matching refs:DVar

256     DSAVarData DVar = getTopDSA(D, false);  in isThreadPrivate()  local
257 return isOpenMPThreadPrivate(DVar.CKind); in isThreadPrivate()
412 DSAVarData DVar; in getDSA() local
420 DVar.CKind = OMPC_shared; in getDSA()
427 DVar.CKind = OMPC_shared; in getDSA()
431 DVar.CKind = OMPC_shared; in getDSA()
433 return DVar; in getDSA()
436 DVar.DKind = Iter->Directive; in getDSA()
443 DVar.CKind = OMPC_private; in getDSA()
444 return DVar; in getDSA()
450 DVar.RefExpr = Iter->SharingMap[D].RefExpr.getPointer(); in getDSA()
451 DVar.PrivateCopy = Iter->SharingMap[D].PrivateCopy; in getDSA()
452 DVar.CKind = Iter->SharingMap[D].Attributes; in getDSA()
453 DVar.ImplicitDSALoc = Iter->DefaultAttrLoc; in getDSA()
454 return DVar; in getDSA()
463 DVar.CKind = OMPC_shared; in getDSA()
464 DVar.ImplicitDSALoc = Iter->DefaultAttrLoc; in getDSA()
465 return DVar; in getDSA()
467 return DVar; in getDSA()
473 DVar.ImplicitDSALoc = Iter->DefaultAttrLoc; in getDSA()
474 if (isOpenMPParallelDirective(DVar.DKind) || in getDSA()
475 isOpenMPTeamsDirective(DVar.DKind)) { in getDSA()
476 DVar.CKind = OMPC_shared; in getDSA()
477 return DVar; in getDSA()
485 if (isOpenMPTaskingDirective(DVar.DKind)) { in getDSA()
496 DVar.RefExpr = nullptr; in getDSA()
497 DVar.CKind = OMPC_firstprivate; in getDSA()
498 return DVar; in getDSA()
503 DVar.CKind = in getDSA()
505 return DVar; in getDSA()
646 DSAVarData DVar; in getTopDSA() local
663 DVar.RefExpr = Stack[0].SharingMap[D].RefExpr.getPointer(); in getTopDSA()
664 DVar.CKind = OMPC_threadprivate; in getTopDSA()
665 return DVar; in getTopDSA()
670 return DVar; in getTopDSA()
684 return DVar; in getTopDSA()
686 DVar.CKind = OMPC_shared; in getTopDSA()
687 return DVar; in getTopDSA()
711 return DVar; in getTopDSA()
713 DVar.CKind = OMPC_shared; in getTopDSA()
714 return DVar; in getTopDSA()
726 DVar.RefExpr = I->SharingMap[D].RefExpr.getPointer(); in getTopDSA()
727 DVar.PrivateCopy = I->SharingMap[D].PrivateCopy; in getTopDSA()
728 DVar.CKind = I->SharingMap[D].Attributes; in getTopDSA()
729 DVar.ImplicitDSALoc = I->DefaultAttrLoc; in getTopDSA()
732 return DVar; in getTopDSA()
760 DSAVarData DVar = getDSA(I, D); in hasDSA() local
761 if (CPred(DVar.CKind)) in hasDSA()
762 return DVar; in hasDSA()
780 DSAVarData DVar = getDSA(I, D); in hasInnermostDSA() local
781 if (CPred(DVar.CKind)) in hasInnermostDSA()
782 return DVar; in hasInnermostDSA()
1077 auto DVar = DSAStack->getTopDSA(VD, false); in EndOpenMPDSABlock() local
1078 if (DVar.CKind == OMPC_lastprivate) { in EndOpenMPDSABlock()
1398 const ValueDecl *D, DSAStackTy::DSAVarData DVar, in ReportOriginalDSA() argument
1400 if (DVar.RefExpr) { in ReportOriginalDSA()
1401 SemaRef.Diag(DVar.RefExpr->getExprLoc(), diag::note_omp_explicit_dsa) in ReportOriginalDSA()
1402 << getOpenMPClauseName(DVar.CKind); in ReportOriginalDSA()
1421 if (DVar.CKind == OMPC_private) in ReportOriginalDSA()
1423 else if (DVar.CKind == OMPC_lastprivate) in ReportOriginalDSA()
1427 } else if (isOpenMPTaskingDirective(DVar.DKind) && in ReportOriginalDSA()
1428 DVar.CKind == OMPC_firstprivate) { in ReportOriginalDSA()
1430 ReportLoc = DVar.ImplicitDSALoc; in ReportOriginalDSA()
1439 else if (VD && VD->isLocalVarDecl() && DVar.CKind == OMPC_private) { in ReportOriginalDSA()
1447 } else if (DVar.ImplicitDSALoc.isValid()) { in ReportOriginalDSA()
1448 SemaRef.Diag(DVar.ImplicitDSALoc, diag::note_omp_implicit_dsa) in ReportOriginalDSA()
1449 << getOpenMPClauseName(DVar.CKind); in ReportOriginalDSA()
1472 auto DVar = Stack->getTopDSA(VD, false); in VisitDeclRefExpr() local
1474 if (DVar.RefExpr) return; in VisitDeclRefExpr()
1482 if (DVar.CKind == OMPC_unknown && Stack->getDefaultDSA() == DSA_none && in VisitDeclRefExpr()
1493 DVar = Stack->hasInnermostDSA( in VisitDeclRefExpr()
1500 if (isOpenMPTaskingDirective(DKind) && DVar.CKind == OMPC_reduction) { in VisitDeclRefExpr()
1503 ReportOriginalDSA(SemaRef, Stack, VD, DVar); in VisitDeclRefExpr()
1508 DVar = Stack->getImplicitDSA(VD, false); in VisitDeclRefExpr()
1509 if (isOpenMPTaskingDirective(DKind) && DVar.CKind != OMPC_shared && in VisitDeclRefExpr()
1520 auto DVar = Stack->getTopDSA(FD, false); in VisitMemberExpr() local
1523 if (DVar.RefExpr) in VisitMemberExpr()
1532 DVar = Stack->hasInnermostDSA( in VisitMemberExpr()
1540 if (isOpenMPTaskingDirective(DKind) && DVar.CKind == OMPC_reduction) { in VisitMemberExpr()
1543 ReportOriginalDSA(SemaRef, Stack, FD, DVar); in VisitMemberExpr()
1548 DVar = Stack->getImplicitDSA(FD, false); in VisitMemberExpr()
1549 if (isOpenMPTaskingDirective(DKind) && DVar.CKind != OMPC_shared && in VisitMemberExpr()
4689 DSAStackTy::DSAVarData DVar = DSA.getTopDSA(LCDecl, false); in CheckOpenMPIterationSpace() local
4696 if (((isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && in CheckOpenMPIterationSpace()
4697 DVar.CKind != PredeterminedCKind) || in CheckOpenMPIterationSpace()
4700 !isOpenMPSimdDirective(DKind) && DVar.CKind != OMPC_unknown && in CheckOpenMPIterationSpace()
4701 DVar.CKind != OMPC_private && DVar.CKind != OMPC_lastprivate)) && in CheckOpenMPIterationSpace()
4702 (DVar.CKind != OMPC_private || DVar.RefExpr != nullptr)) { in CheckOpenMPIterationSpace()
4704 << getOpenMPClauseName(DVar.CKind) << getOpenMPDirectiveName(DKind) in CheckOpenMPIterationSpace()
4706 if (DVar.RefExpr == nullptr) in CheckOpenMPIterationSpace()
4707 DVar.CKind = PredeterminedCKind; in CheckOpenMPIterationSpace()
4708 ReportOriginalDSA(SemaRef, &DSA, LCDecl, DVar, /*IsLoopIterVar=*/true); in CheckOpenMPIterationSpace()
4715 if (DVar.CKind == OMPC_unknown) in CheckOpenMPIterationSpace()
4716 DVar = DSA.hasDSA(LCDecl, isOpenMPPrivate, in CheckOpenMPIterationSpace()
8239 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPPrivateClause() local
8240 if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_private) { in ActOnOpenMPPrivateClause()
8241 Diag(ELoc, diag::err_omp_wrong_dsa) << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPPrivateClause()
8243 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPPrivateClause()
8273 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPPrivateClause()
8385 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPFirstprivateClause() local
8386 TopDVar = DVar; in ActOnOpenMPFirstprivateClause()
8392 if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_firstprivate && in ActOnOpenMPFirstprivateClause()
8393 DVar.CKind != OMPC_lastprivate && DVar.RefExpr) { in ActOnOpenMPFirstprivateClause()
8395 << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPFirstprivateClause()
8397 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8412 if (!(IsConstant || (VD && VD->isStaticDataMember())) && !DVar.RefExpr && in ActOnOpenMPFirstprivateClause()
8413 DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_shared) { in ActOnOpenMPFirstprivateClause()
8415 << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPFirstprivateClause()
8417 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8429 DVar = DSAStack->getImplicitDSA(D, true); in ActOnOpenMPFirstprivateClause()
8430 if (DVar.CKind != OMPC_shared && in ActOnOpenMPFirstprivateClause()
8431 (isOpenMPParallelDirective(DVar.DKind) || in ActOnOpenMPFirstprivateClause()
8432 DVar.DKind == OMPD_unknown)) { in ActOnOpenMPFirstprivateClause()
8436 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8452 DVar = DSAStack->hasInnermostDSA( in ActOnOpenMPFirstprivateClause()
8459 if (DVar.CKind == OMPC_reduction && in ActOnOpenMPFirstprivateClause()
8460 (isOpenMPParallelDirective(DVar.DKind) || in ActOnOpenMPFirstprivateClause()
8461 isOpenMPWorksharingDirective(DVar.DKind))) { in ActOnOpenMPFirstprivateClause()
8463 << getOpenMPDirectiveName(DVar.DKind); in ActOnOpenMPFirstprivateClause()
8464 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8483 DVar = DSAStack->hasInnermostDSA( in ActOnOpenMPFirstprivateClause()
8489 if (DVar.CKind == OMPC_private && isOpenMPTeamsDirective(DVar.DKind)) { in ActOnOpenMPFirstprivateClause()
8491 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8494 DVar = DSAStack->hasInnermostDSA( in ActOnOpenMPFirstprivateClause()
8500 if (DVar.CKind == OMPC_reduction && in ActOnOpenMPFirstprivateClause()
8501 isOpenMPTeamsDirective(DVar.DKind)) { in ActOnOpenMPFirstprivateClause()
8503 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8506 DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPFirstprivateClause()
8507 if (DVar.CKind == OMPC_lastprivate) { in ActOnOpenMPFirstprivateClause()
8509 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8524 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPFirstprivateClause()
8665 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPLastprivateClause() local
8666 if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_lastprivate && in ActOnOpenMPLastprivateClause()
8667 DVar.CKind != OMPC_firstprivate && in ActOnOpenMPLastprivateClause()
8668 (DVar.CKind != OMPC_private || DVar.RefExpr != nullptr)) { in ActOnOpenMPLastprivateClause()
8670 << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPLastprivateClause()
8672 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPLastprivateClause()
8683 DSAStackTy::DSAVarData TopDVar = DVar; in ActOnOpenMPLastprivateClause()
8686 DVar = DSAStack->getImplicitDSA(D, true); in ActOnOpenMPLastprivateClause()
8687 if (DVar.CKind != OMPC_shared) { in ActOnOpenMPLastprivateClause()
8691 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPLastprivateClause()
8700 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPLastprivateClause() local
8701 if (DVar.CKind == OMPC_firstprivate) { in ActOnOpenMPLastprivateClause()
8703 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPLastprivateClause()
8806 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPSharedClause() local
8807 if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_shared && in ActOnOpenMPSharedClause()
8808 DVar.RefExpr) { in ActOnOpenMPSharedClause()
8809 Diag(ELoc, diag::err_omp_wrong_dsa) << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPSharedClause()
8811 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPSharedClause()
8837 DSAStackTy::DSAVarData DVar = Stack->getTopDSA(VD, false); in VisitDeclRefExpr() local
8838 if (DVar.CKind == OMPC_shared && !DVar.RefExpr) in VisitDeclRefExpr()
8840 if (DVar.CKind != OMPC_unknown) in VisitDeclRefExpr()
9194 DSAStackTy::DSAVarData DVar; in ActOnOpenMPReductionClause() local
9195 DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPReductionClause()
9196 if (DVar.CKind == OMPC_reduction) { in ActOnOpenMPReductionClause()
9199 if (DVar.RefExpr) in ActOnOpenMPReductionClause()
9200 Diag(DVar.RefExpr->getExprLoc(), diag::note_omp_referenced); in ActOnOpenMPReductionClause()
9201 } else if (DVar.CKind != OMPC_unknown) { in ActOnOpenMPReductionClause()
9203 << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPReductionClause()
9205 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPReductionClause()
9216 DVar = DSAStack->getImplicitDSA(D, true); in ActOnOpenMPReductionClause()
9217 if (DVar.CKind != OMPC_shared) { in ActOnOpenMPReductionClause()
9221 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPReductionClause()
9640 DSAStackTy::DSAVarData DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPLinearClause() local
9641 if (DVar.RefExpr) { in ActOnOpenMPLinearClause()
9642 Diag(ELoc, diag::err_omp_wrong_dsa) << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPLinearClause()
9644 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPLinearClause()
10028 auto DVar = DSAStack->getTopDSA(D, false); in ActOnOpenMPCopyprivateClause() local
10029 if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_copyprivate && in ActOnOpenMPCopyprivateClause()
10030 DVar.RefExpr) { in ActOnOpenMPCopyprivateClause()
10032 << getOpenMPClauseName(DVar.CKind) in ActOnOpenMPCopyprivateClause()
10034 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPCopyprivateClause()
10041 if (DVar.CKind == OMPC_unknown) { in ActOnOpenMPCopyprivateClause()
10042 DVar = DSAStack->getImplicitDSA(D, false); in ActOnOpenMPCopyprivateClause()
10043 if (DVar.CKind == OMPC_shared) { in ActOnOpenMPCopyprivateClause()
10047 ReportOriginalDSA(*this, DSAStack, D, DVar); in ActOnOpenMPCopyprivateClause()
10941 auto DVar = DSAS->getTopDSA(VD, false); in checkMappableExpressionList() local
10944 ReportOriginalDSA(SemaRef, DSAS, VD, DVar); in checkMappableExpressionList()
11011 auto DVar = DSAS->getTopDSA(VD, false); in checkMappableExpressionList() local
11012 if (isOpenMPPrivate(DVar.CKind)) { in checkMappableExpressionList()
11014 << getOpenMPClauseName(DVar.CKind) in checkMappableExpressionList()
11016 ReportOriginalDSA(SemaRef, DSAS, CurDeclaration, DVar); in checkMappableExpressionList()