Home
last modified time | relevance | path

Searched refs:VarDecl (Results 1 – 25 of 224) sorted by relevance

123456789

/external/clang/lib/Analysis/
DPseudoConstantAnalysis.cpp27 typedef llvm::SmallPtrSet<const VarDecl*, VARDECL_SET_SIZE> VarDeclSet;
41 bool PseudoConstantAnalysis::isPseudoConstant(const VarDecl *VD) { in isPseudoConstant()
57 bool PseudoConstantAnalysis::wasReferenced(const VarDecl *VD) { in wasReferenced()
124 const VarDecl *VD = dyn_cast<VarDecl>(LHSDecl); in RunAnalysis()
158 const VarDecl *VD = dyn_cast<VarDecl>(D); in RunAnalysis()
176 const VarDecl *VD = dyn_cast<VarDecl>(I); in RunAnalysis()
191 if (const VarDecl *RefVD = dyn_cast<VarDecl>(D)) { in RunAnalysis()
202 if (const VarDecl *VD = dyn_cast<VarDecl>(DR->getDecl())) { in RunAnalysis()
DUninitializedValues.cpp36 static bool isTrackedVar(const VarDecl *vd, const DeclContext *dc) { in isTrackedVar()
52 llvm::DenseMap<const VarDecl *, unsigned> map;
63 Optional<unsigned> getValueIndex(const VarDecl *d) const;
69 DeclContext::specific_decl_iterator<VarDecl> I(dc.decls_begin()), in computeMap()
72 const VarDecl *vd = *I; in computeMap()
78 Optional<unsigned> DeclToIndex::getValueIndex(const VarDecl *d) const { in getValueIndex()
79 llvm::DenseMap<const VarDecl *, unsigned>::const_iterator I = map.find(d); in getValueIndex()
132 ValueVector::reference operator[](const VarDecl *vd);
135 const VarDecl *vd) { in getValue()
196 ValueVector::reference CFGBlockValues::operator[](const VarDecl *vd) { in operator []()
[all …]
DLiveVariables.cpp86 llvm::ImmutableSet<const VarDecl *>::Factory DSetFact;
123 bool LiveVariables::LivenessValues::isLive(const VarDecl *D) const { in isLive()
151 llvm::ImmutableSetRef<const VarDecl *> in merge()
173 static bool isAlwaysAlive(const VarDecl *D) { in isAlwaysAlive()
177 bool LiveVariables::isLive(const CFGBlock *B, const VarDecl *D) { in isLive()
181 bool LiveVariables::isLive(const Stmt *S, const VarDecl *D) { in isLive()
291 if (const VarDecl *VD = dyn_cast<VarDecl>(DS->getSingleDecl())) { in Visit()
341 if (const VarDecl *VD = dyn_cast<VarDecl>(DR->getDecl())) { in VisitBinaryOperator()
358 for (const VarDecl *VD : in VisitBlockExpr()
367 if (const VarDecl *D = dyn_cast<VarDecl>(DR->getDecl())) in VisitDeclRefExpr()
[all …]
/external/clang/lib/ARCMigrate/
DTransBlockObjCVariable.cpp42 llvm::DenseSet<VarDecl *> &VarsToChange;
45 VarDecl *Var;
49 BlockVarChecker(VarDecl *var) : Var(var) { } in BlockVarChecker()
75 RootBlockObjCVarRewriter(llvm::DenseSet<VarDecl *> &VarsToChange) in RootBlockObjCVarRewriter()
79 SmallVector<VarDecl *, 4> BlockVars; in VisitBlockDecl()
82 VarDecl *var = I.getVariable(); in VisitBlockDecl()
91 VarDecl *var = BlockVars[i]; in VisitBlockDecl()
113 llvm::DenseSet<VarDecl *> &VarsToChange;
116 BlockObjCVarRewriter(llvm::DenseSet<VarDecl *> &VarsToChange) in BlockObjCVarRewriter()
129 llvm::DenseSet<VarDecl *> VarsToChange; in traverseBody()
[all …]
DTransARCAssign.cpp37 llvm::DenseSet<VarDecl *> ModifiedVars;
50 if (declRef && isa<VarDecl>(declRef->getDecl())) { in VisitBinaryOperator()
55 VarDecl *var = cast<VarDecl>(declRef->getDecl()); in VisitBinaryOperator()
DTransAutoreleasePool.cpp85 SmallVector<VarDecl *, 8> VarsToHandle; in ~AutoreleasePoolRewriter()
87 for (std::map<VarDecl *, PoolVarInfo>::iterator in ~AutoreleasePoolRewriter()
89 VarDecl *var = I->first; in ~AutoreleasePoolRewriter()
172 if (VarDecl *VD = dyn_cast<VarDecl>(DclS->getSingleDecl())) { in VisitCompoundStmt()
190 if (VarDecl *VD = dyn_cast<VarDecl>(dref->getDecl())) { in VisitCompoundStmt()
226 VarDecl *PoolVar;
373 bool isPoolDrain(VarDecl *poolVar, Stmt *S) { in isPoolDrain()
427 std::map<VarDecl *, PoolVarInfo> PoolVars;
/external/clang/lib/StaticAnalyzer/Checkers/
DDeadStoresChecker.cpp37 llvm::DenseSet<const VarDecl *> &S;
56 if (const VarDecl *D = dyn_cast<VarDecl>(DR->getDecl())) in VisitDeclRefExpr()
61 EHCodeVisitor(llvm::DenseSet<const VarDecl *> &S) : in EHCodeVisitor()
130 llvm::SmallPtrSet<const VarDecl*, 20> Escaped;
133 std::unique_ptr<llvm::DenseSet<const VarDecl *>> InEH;
141 llvm::SmallPtrSet<const VarDecl *, 20> &escaped) in DeadStoreObs() argument
147 bool isLive(const LiveVariables::LivenessValues &Live, const VarDecl *D) { in isLive()
153 InEH.reset(new llvm::DenseSet<const VarDecl *>()); in isLive()
164 void Report(const VarDecl *V, DeadStoreKind dsk, in Report()
208 void CheckVarDecl(const VarDecl *VD, const Expr *Ex, const Expr *Val, in CheckVarDecl()
[all …]
/external/clang/unittests/AST/
DASTTypeTraitsTest.cpp32 EXPECT_FALSE(DNT<VarDecl>().isNone()); in TEST()
36 EXPECT_TRUE(DNT<Decl>().isBaseOf(DNT<VarDecl>())); in TEST()
37 EXPECT_FALSE(DNT<Decl>().isSame(DNT<VarDecl>())); in TEST()
38 EXPECT_FALSE(DNT<VarDecl>().isBaseOf(DNT<Decl>())); in TEST()
74 EXPECT_TRUE(DNT<VarDecl>().isSame( in TEST()
75 ASTNodeKind::getMostDerivedType(DNT<VarDecl>(), DNT<VarDecl>()))); in TEST()
79 ASTNodeKind::getMostDerivedType(DNT<IfStmt>(), DNT<VarDecl>()).isNone()); in TEST()
89 EXPECT_TRUE(DNT<VarDecl>().isSame(ASTNodeKind::getMostDerivedCommonAncestor( in TEST()
90 DNT<VarDecl>(), DNT<VarDecl>()))); in TEST()
99 DNT<IfStmt>(), DNT<VarDecl>()).isNone()); in TEST()
/external/clang/lib/StaticAnalyzer/Core/
DCheckerHelpers.cpp52 if (const VarDecl *VD = dyn_cast<VarDecl>(DR->getDecl())) in containsStaticLocal()
76 std::pair<const clang::VarDecl *, const clang::Expr *>
78 const VarDecl *VD = 0; in parseAssignment()
86 VD = dyn_cast_or_null<VarDecl>(DE->getDecl()); in parseAssignment()
91 VD = dyn_cast_or_null<VarDecl>(PD->getSingleDecl()); in parseAssignment()
/external/clang/lib/AST/
DStmtIterator.cpp44 if (VarDecl* VD = dyn_cast<VarDecl>(*DGI)) in NextVA()
71 if (VarDecl* VD = dyn_cast<VarDecl>(D)) { in HandleDecl()
112 VarDecl* VD = cast<VarDecl>(*DGI); in GetDeclExpr()
DStmtCXX.cpp69 VarDecl *RangeDecl = dyn_cast_or_null<VarDecl>(RangeStmt->getSingleDecl()); in getRangeInit()
78 VarDecl *CXXForRangeStmt::getLoopVariable() { in getLoopVariable()
81 return cast<VarDecl>(LV); in getLoopVariable()
84 const VarDecl *CXXForRangeStmt::getLoopVariable() const { in getLoopVariable()
DDecl.cpp589 if (const auto *Var = dyn_cast<VarDecl>(D)) { in getLVForNamespaceScopeDecl()
600 const VarDecl *PrevVar = Var->getPreviousDecl(); in getLVForNamespaceScopeDecl()
610 for (const VarDecl *PrevVar = Var->getPreviousDecl(); PrevVar; in getLVForNamespaceScopeDecl()
629 const VarDecl *VD = IFD->getVarDecl(); in getLVForNamespaceScopeDecl()
636 const auto *Var = dyn_cast<VarDecl>(D); in getLVForNamespaceScopeDecl()
696 if (const auto *Var = dyn_cast<VarDecl>(D)) { in getLVForNamespaceScopeDecl()
858 isa<VarDecl>(D) || in getLVForClassMember()
950 } else if (const auto *VD = dyn_cast<VarDecl>(D)) { in getLVForClassMember()
1071 if (const auto *Var = dyn_cast<VarDecl>(ND)) { in getExplicitVisibilityAux()
1073 VarDecl *InstantiatedFrom = Var->getInstantiatedFromStaticDataMember(); in getExplicitVisibilityAux()
[all …]
/external/clang/include/clang/Analysis/Analyses/
DLiveVariables.h36 llvm::ImmutableSet<const VarDecl *> liveDecls;
44 llvm::ImmutableSet<const VarDecl *> LiveDecls) in LivenessValues()
48 bool isLive(const VarDecl *D) const;
77 bool isLive(const CFGBlock *B, const VarDecl *D);
83 bool isLive(const Stmt *S, const VarDecl *D);
/external/clang/include/clang/AST/
DLambdaCapture.h63 VarDecl *Var = nullptr,
78 return dyn_cast_or_null<VarDecl>(DeclAndBits.getPointer()); in capturesVariable()
93 VarDecl *getCapturedVar() const { in getCapturedVar()
95 return cast<VarDecl>(DeclAndBits.getPointer()); in getCapturedVar()
DMangle.h37 class VarDecl; variable
105 virtual void mangleReferenceTemporary(const VarDecl *D,
128 virtual void mangleStaticGuardVariable(const VarDecl *D, raw_ostream &) = 0;
130 virtual void mangleDynamicInitializer(const VarDecl *D, raw_ostream &) = 0;
132 virtual void mangleDynamicAtExitDestructor(const VarDecl *D,
160 virtual void mangleItaniumThreadLocalInit(const VarDecl *D,
162 virtual void mangleItaniumThreadLocalWrapper(const VarDecl *D,
197 virtual void mangleThreadSafeStaticGuardVariable(const VarDecl *VD,
DMangleNumberingContext.h29 class VarDecl; variable
46 virtual unsigned getStaticLocalNumber(const VarDecl *VD) = 0;
50 virtual unsigned getManglingNumber(const VarDecl *VD,
/external/clang/include/clang/Sema/
DScopeInfo.h44 class VarDecl; variable
149 VarDecl *CoroutinePromise;
412 llvm::PointerIntPair<VarDecl*, 1, bool> VarAndNested;
431 Capture(VarDecl *Var, bool Block, bool ByRef, bool IsNested, in Capture()
468 VarDecl *getVariable() const { in getVariable()
496 llvm::DenseMap<VarDecl*, unsigned> CaptureMap;
513 void addCapture(VarDecl *Var, bool isBlock, bool isByref, bool isNested, in addCapture()
541 bool isCaptured(VarDecl *Var) const { in isCaptured()
550 Capture &getCapture(VarDecl *Var) { in getCapture()
555 const Capture &getCapture(VarDecl *Var) const { in getCapture()
[all …]
/external/clang/test/Index/
Dannotate-subscripting.m47 // CHECK: Punctuation: "*" [25:11 - 25:12] VarDecl=arr:25:12 (Definition)
48 // CHECK: Identifier: "arr" [25:12 - 25:15] VarDecl=arr:25:12 (Definition)
49 // CHECK: Punctuation: "=" [25:16 - 25:17] VarDecl=arr:25:12 (Definition)
79 // CHECK: Punctuation: "*" [35:16 - 35:17] VarDecl=dict:35:17 (Definition)
80 // CHECK: Identifier: "dict" [35:17 - 35:21] VarDecl=dict:35:17 (Definition)
81 // CHECK: Punctuation: "=" [35:22 - 35:23] VarDecl=dict:35:17 (Definition)
Dc-index-getCursor-test.m116 // CHECK: [45:5 - 45:11] VarDecl=bee:45:8 (Definition)
120 // CHECK: [46:4 - 46:9] VarDecl=a:46:5 (Definition)
127 // CHECK: [47:4 - 47:6] VarDecl=c:47:12 (Definition)
129 // CHECK: [47:10 - 47:16] VarDecl=c:47:12 (Definition)
136 // CHECK: [48:4 - 48:6] VarDecl=d:48:13 (Definition)
138 // CHECK: [48:11 - 48:14] VarDecl=d:48:13 (Definition)
167 // CHECK: [58:4 - 58:8] VarDecl=my_var:58:8 (Definition)
Dannotate-literals.m52 // CHECK-LITERALS: Identifier: "objects" [41:6 - 41:13] VarDecl=objects:41:6 (Definition)
53 // CHECK-LITERALS: Punctuation: "=" [41:14 - 41:15] VarDecl=objects:41:6 (Definition)
62 // CHECK-LITERALS: Identifier: "dict" [42:6 - 42:10] VarDecl=dict:42:6 (Definition)
63 // CHECK-LITERALS: Punctuation: "=" [42:11 - 42:12] VarDecl=dict:42:6 (Definition)
81 // CHECK-LITERALS: Identifier: "val" [45:6 - 45:9] VarDecl=val:45:6 (Definition)
82 // CHECK-LITERALS: Punctuation: "=" [45:10 - 45:11] VarDecl=val:45:6 (Definition)
Dannotate-module.m25 // CHECK-NEXT: Keyword: "int" [4:1 - 4:4] VarDecl=glob:4:5
26 // CHECK-NEXT: Identifier: "glob" [4:5 - 4:9] VarDecl=glob:4:5
41 // CHECK-MOD-NEXT: Keyword: "int" [2:1 - 2:4] VarDecl=Module_Sub:2:6
42 // CHECK-MOD-NEXT: Punctuation: "*" [2:5 - 2:6] VarDecl=Module_Sub:2:6
43 // CHECK-MOD-NEXT: Identifier: "Module_Sub" [2:6 - 2:16] VarDecl=Module_Sub:2:6
/external/clang/lib/CodeGen/
DCGStmtOpenMP.cpp90 VarDecl *CapVar = nullptr; in GenerateOpenMPCapturedStmtFunction()
318 Address SrcAddr, const VarDecl *DestVD, in EmitOMPCopy()
319 const VarDecl *SrcVD, const Expr *Copy) { in EmitOMPCopy()
359 llvm::DenseSet<const VarDecl *> EmittedAsFirstprivate; in EmitOMPFirstprivateClause()
364 auto *OrigVD = cast<VarDecl>(cast<DeclRefExpr>(*IRef)->getDecl()); in EmitOMPFirstprivateClause()
367 auto *VD = cast<VarDecl>(cast<DeclRefExpr>(IInit)->getDecl()); in EmitOMPFirstprivateClause()
368 auto *VDInit = cast<VarDecl>(cast<DeclRefExpr>(*InitsRef)->getDecl()); in EmitOMPFirstprivateClause()
371 const_cast<VarDecl *>(OrigVD), in EmitOMPFirstprivateClause()
434 llvm::DenseSet<const VarDecl *> EmittedAsPrivate; in EmitOMPPrivateClause()
438 auto *OrigVD = cast<VarDecl>(cast<DeclRefExpr>(*IRef)->getDecl()); in EmitOMPPrivateClause()
[all …]
DCGDecl.cpp112 const VarDecl &VD = cast<VarDecl>(D); in EmitDecl()
131 void CodeGenFunction::EmitVarDecl(const VarDecl &D) { in EmitVarDecl()
154 static std::string getStaticDeclName(CodeGenModule &CGM, const VarDecl &D) { in getStaticDeclName()
178 const VarDecl &D, llvm::GlobalValue::LinkageTypes Linkage) { in getOrCreateStaticVarDecl()
283 CodeGenFunction::AddInitializerToStaticVarDecl(const VarDecl &D, in AddInitializerToStaticVarDecl()
343 void CodeGenFunction::EmitStaticVarDecl(const VarDecl &D, in EmitStaticVarDecl()
470 const VarDecl &Var;
471 ExtendGCLifetime(const VarDecl *var) : Var(*var) {} in ExtendGCLifetime()
476 DeclRefExpr DRE(const_cast<VarDecl*>(&Var), false, in Emit()
487 const VarDecl &Var;
[all …]
DCodeGenModule.h69 class VarDecl; variable
381 std::vector<const VarDecl *> CXXThreadLocals;
386 std::vector<const VarDecl *> CXXThreadLocalInitVars;
540 llvm::Constant *getStaticLocalDeclAddress(const VarDecl *D) { in getStaticLocalDeclAddress()
543 void setStaticLocalDeclAddress(const VarDecl *D, in setStaticLocalDeclAddress()
549 getOrCreateStaticVarDecl(const VarDecl &D,
552 llvm::GlobalVariable *getStaticLocalDeclGuardAddress(const VarDecl *D) { in getStaticLocalDeclGuardAddress()
555 void setStaticLocalDeclGuardAddress(const VarDecl *D, in setStaticLocalDeclGuardAddress()
665 void setTLSMode(llvm::GlobalValue *GV, const VarDecl &D) const;
696 unsigned GetGlobalVarAddressSpace(const VarDecl *D, unsigned AddrSpace);
[all …]
/external/clang/lib/Sema/
DSemaOpenMP.cpp90 typedef llvm::SmallDenseMap<VarDecl *, DSAInfo, 64> DeclSAMapTy;
91 typedef llvm::SmallDenseMap<VarDecl *, DeclRefExpr *, 64> AlignedMapTy;
92 typedef llvm::DenseSet<VarDecl *> LoopControlVariablesSetTy;
93 typedef llvm::SmallDenseMap<VarDecl *, MapInfo, 64> MappedDeclsTy;
142 DSAVarData getDSA(StackTy::reverse_iterator Iter, VarDecl *D);
145 bool isOpenMPLocal(VarDecl *D, StackTy::reverse_iterator Iter);
182 DeclRefExpr *addUniqueAligned(VarDecl *D, DeclRefExpr *NewDE);
185 void addLoopControlVariable(VarDecl *D);
188 bool isLoopControlVariable(VarDecl *D);
191 void addDSA(VarDecl *D, DeclRefExpr *E, OpenMPClauseKind A);
[all …]

123456789