Home
last modified time | relevance | path

Searched refs:LCtx (Results 1 – 25 of 56) sorted by relevance

123

/freebsd-13.1/contrib/llvm-project/clang/lib/StaticAnalyzer/Core/
H A DExprEngineC.cpp58 SVal LeftV = state->getSVal(LHS, LCtx); in VisitBinaryOperator()
59 SVal RightV = state->getSVal(RHS, LCtx); in VisitBinaryOperator()
141 SVal V = state->getSVal(LHS, LCtx); in VisitBinaryOperator()
271 SVal OrigV = state->getSVal(Ex, LCtx); in handleLValueBitCast()
276 state = state->BindExpr(CastE, LCtx, V); in handleLValueBitCast()
345 SVal V = state->getSVal(Ex, LCtx); in VisitCast()
352 SVal V = state->getSVal(Ex, LCtx); in VisitCast()
373 SVal V = state->getSVal(Ex, LCtx); in VisitCast()
418 SVal V = state->getSVal(Ex, LCtx); in VisitCast()
1018 SVal V = state->getSVal(Ex, LCtx); in VisitUnaryOperator()
[all …]
H A DExprEngineCXX.cpp85 PostStmt PS(CallExpr, LCtx); in performTrivialCopy()
90 State = State->BindExpr(CallExpr, LCtx, ThisVal); in performTrivialCopy()
92 State = bindReturnValue(Call, LCtx, State); in performTrivialCopy()
512 LCtx->getStackFrame()->getCallSite()); in handleConstructor()
576 CIE, TargetRegion, State, LCtx) in handleConstructor()
578 CE, TargetRegion, State, LCtx); in handleConstructor()
775 CEMgr.getCXXAllocatorCall(CNE, State, LCtx); in VisitCXXNewAllocatorCall()
804 SVal RetVal = State->getSVal(CNE, LCtx); in VisitCXXNewAllocatorCall()
868 CEMgr.getCXXAllocatorCall(CNE, State, LCtx); in VisitCXXNewExpr()
925 State = State->BindExpr(CNE, LCtx, Result); in VisitCXXNewExpr()
[all …]
H A DProgramState.cpp95 ProgramStateRef state, const StackFrameContext *LCtx, in removeDeadBindingsFromEnvironmentAndStore() argument
119 const LocationContext *LCtx, in bindLoc() argument
156 const LocationContext *LCtx, in invalidateRegions() argument
173 const LocationContext *LCtx, in invalidateRegions() argument
186 const LocationContext *LCtx, in invalidateRegionsImpl() argument
219 Invalidated, LCtx, Call); in invalidateRegionsImpl()
243 SVal ProgramState::getSelfSVal(const LocationContext *LCtx) const { in getSelfSVal()
244 const ImplicitParamDecl *SelfDecl = LCtx->getSelfDecl(); in getSelfSVal()
247 return getSVal(getRegion(SelfDecl, LCtx)); in getSelfSVal()
461 Env.printJson(Out, Mgr.getContext(), LCtx, NL, Space, IsDot); in printJson()
[all …]
H A DLoopWidening.cpp45 const LocationContext *LCtx, in getWidenedLoopState() argument
57 ASTContext &ASTCtx = LCtx->getAnalysisDeclContext()->getASTContext(); in getWidenedLoopState()
58 const StackFrameContext *STC = LCtx->getStackFrame(); in getWidenedLoopState()
73 *LCtx->getDecl()->getBody(), ASTCtx); in getWidenedLoopState()
77 const VarRegion *VarMem = MRMgr.getVarRegion(VD, LCtx); in getWidenedLoopState()
96 BlockCount, LCtx, true, nullptr, nullptr, in getWidenedLoopState()
H A DPrettyStackTraceLocationContext.h29 const LocationContext *LCtx; variable
31 PrettyStackTraceLocationContext(const LocationContext *LC) : LCtx(LC) { in PrettyStackTraceLocationContext()
32 assert(LCtx); in PrettyStackTraceLocationContext()
37 LCtx->dumpStack(Out); in print()
H A DEnvironment.cpp95 const LocationContext *LCtx = Entry.getLocationContext(); in getSVal() local
126 return getSVal(EnvironmentEntry(RE, LCtx), svalBuilder); in getSVal()
132 return lookupExpr(EnvironmentEntry(S, LCtx)); in getSVal()
216 const LocationContext *LCtx, const char *NL, in printJson() argument
226 if (!LCtx) { in printJson()
233 LCtx = LC; in printJson()
240 assert(LCtx); in printJson()
242 Out << "{ \"pointer\": \"" << (const void *)LCtx->getStackFrame() in printJson()
246 LCtx->printJson(Out, NL, Space, IsDot, [&](const LocationContext *LC) { in printJson()
H A DSymbolManager.cpp75 << LCtx->getID(); in dumpToStream()
77 os << ", S" << S->getID(LCtx->getDecl()->getASTContext()); in dumpToStream()
178 SymbolConjured::Profile(profile, E, T, Count, LCtx, SymbolTag); in conjureSymbol()
183 new (SD) SymbolConjured(SymbolCounter, E, LCtx, T, Count, SymbolTag); in conjureSymbol()
226 const LocationContext *LCtx, in getMetadataSymbol() argument
229 SymbolMetadata::Profile(profile, R, S, T, LCtx, Count, SymbolTag); in getMetadataSymbol()
493 if (LCtx == nullptr) in isLive()
496 if (LCtx != ELCtx) { in isLive()
499 if (LCtx->isParentOf(ELCtx)) in isLive()
518 if (!LCtx) in isLive()
[all …]
H A DLoopUnrolling.cpp31 const LocationContext *LCtx; member
34 : K(InK), LoopStmt(S), LCtx(L), maxStep(N) {} in LoopState()
48 const LocationContext *getLocationContext() const { return LCtx; } in getLocationContext()
55 ID.AddPointer(LCtx); in Profile()
303 auto LCtx = Pred->getLocationContext(); in updateLoopStack() local
310 LCtx == LS.getHead().getLocationContext()) { in updateLoopStack()
314 LoopState::getNormal(LoopStmt, LCtx, maxVisitOnPath)); in updateLoopStack()
321 LoopState::getNormal(LoopStmt, LCtx, maxVisitOnPath)); in updateLoopStack()
330 LoopState::getNormal(LoopStmt, LCtx, maxVisitOnPath)); in updateLoopStack()
333 LoopState::getUnrolled(LoopStmt, LCtx, innerMaxStep)); in updateLoopStack()
H A DExprEngineObjC.cpp25 const LocationContext *LCtx = Pred->getLocationContext(); in VisitLvalObjCIvarRefExpr() local
26 SVal baseVal = state->getSVal(Ex->getBase(), LCtx); in VisitLvalObjCIvarRefExpr()
31 Bldr.generateNode(Ex, Pred, state->BindExpr(Ex, LCtx, location)); in VisitLvalObjCIvarRefExpr()
54 const LocationContext *LCtx = Pred->getLocationContext(); in populateObjCForDestinationSet() local
57 ExprEngine::setWhetherHasMoreIteration(state, S, LCtx, hasElements); in populateObjCForDestinationSet()
69 SymbolRef Sym = SymMgr.conjureSymbol(elem, LCtx, T, in populateObjCForDestinationSet()
76 nextState = nextState->bindLoc(elementV, V, LCtx); in populateObjCForDestinationSet()
H A DExprEngineCallAndReturn.cpp182 const LocationContext *LCtx = Pred->getLocationContext(); in removeDeadOnEndOfFunction() local
183 removeDead(Pred, Dst, dyn_cast<ReturnStmt>(LastSt), LCtx, in removeDeadOnEndOfFunction()
184 LCtx->getAnalysisDeclContext()->getBody(), in removeDeadOnEndOfFunction()
234 SVal V = state->getSVal(RS, LCtx); in processCallExit()
393 while (LCtx) { in examineStackFrames()
402 LCtx = LCtx->getParent(); in examineStackFrames()
411 LCtx = LCtx->getParent(); in examineStackFrames()
659 return State->BindExpr(E, LCtx, ThisV); in bindReturnValue()
683 State = State->invalidateRegions(TargetR, E, Count, LCtx, in bindReturnValue()
701 ElementCount = State->getSVal(SizeExpr, LCtx); in bindReturnValue()
[all …]
H A DExprEngine.cpp568 if (Key.getLocationContext() != LCtx) in printObjectsUnderConstructionJson()
582 if (Key.getLocationContext() != LCtx) in printObjectsUnderConstructionJson()
993 SVal ArgVal = State->getSVal(Arg, LCtx); in ProcessDeleteDtor()
1002 PostImplicitCall PP(Dtor, DE->getBeginLoc(), LCtx); in ProcessDeleteDtor()
1463 State = State->BindExpr(S, LCtx, *ConstantVal); in Visit()
1506 SVal Val = State->getSVal(Child, LCtx); in Visit()
2076 return state->getSVal(Ex, LCtx); in RecoverCastedSymbol()
2691 state = state->BindExpr(M, LCtx, MDVal); in VisitMemberExpr()
2760 SVal SubExprVal = State->getSVal(SubExpr, LCtx); in VisitAtomicExpr()
2766 LCtx, in VisitAtomicExpr()
[all …]
H A DSValBuilder.cpp137 const LocationContext *LCtx, in conjureSymbolVal() argument
148 T = LCtx->getAnalysisDeclContext()->getASTContext().getPointerType(ExType); in conjureSymbolVal()
150 return conjureSymbolVal(SymbolTag, Ex, LCtx, T, Count); in conjureSymbolVal()
164 SymbolRef sym = SymMgr.conjureSymbol(expr, LCtx, type, count, symbolTag); in conjureSymbolVal()
182 SymbolRef sym = SymMgr.conjureSymbol(stmt, LCtx, type, visitCount); in conjureSymbolVal()
192 const LocationContext *LCtx, in getConjuredHeapSymbolVal() argument
195 return getConjuredHeapSymbolVal(E, LCtx, T, VisitCount); in getConjuredHeapSymbolVal()
200 const LocationContext *LCtx, in getConjuredHeapSymbolVal() argument
207 SymbolRef sym = SymMgr.conjureSymbol(E, LCtx, type, VisitCount); in getConjuredHeapSymbolVal()
214 const LocationContext *LCtx, in getMetadataSymbolVal() argument
[all …]
/freebsd-13.1/contrib/llvm-project/clang/include/clang/StaticAnalyzer/Core/PathSensitive/
H A DCallEvent.h149 const LocationContext *LCtx; variable
180 : State(Original.State), LCtx(Original.LCtx), Origin(Original.Origin), in CallEvent()
219 return LCtx; in getLocationContext()
488 : CallEvent(E, St, LCtx) {} in AnyFunctionCall()
491 : CallEvent(D, St, LCtx) {} in AnyFunctionCall()
562 : CallEvent(CE, St, LCtx) {} in BlockCall()
668 : AnyFunctionCall(D, St, LCtx) {} in CXXInstanceCall()
813 : CXXInstanceCall(DD, St, LCtx) { in CXXDestructorCall()
850 : AnyFunctionCall(E, St, LCtx) { in AnyCXXConstructorCall()
1006 : AnyFunctionCall(E, St, LCtx) {} in CXXAllocatorCall()
[all …]
H A DSymbolManager.h81 const LocationContext *LCtx; variable
88 LCtx(lctx), SymbolTag(symbolTag) { in SymbolConjured()
113 profile.AddPointer(LCtx); in Profile()
120 Profile(profile, S, T, Count, LCtx, SymbolTag); in Profile()
213 const LocationContext *LCtx; variable
220 : SymbolData(SymbolMetadataKind, sym), R(r), S(s), T(t), LCtx(LCtx), in SymbolMetadata()
225 assert(LCtx); in SymbolMetadata()
248 profile.AddPointer(LCtx); in Profile()
254 Profile(profile, R, S, T, LCtx, Count, Tag); in Profile()
444 const LocationContext *LCtx,
[all …]
H A DProgramState.h242 const LocationContext *LCtx,
260 bindDefaultZero(SVal loc, const LocationContext *LCtx) const;
284 unsigned BlockCount, const LocationContext *LCtx,
291 unsigned BlockCount, const LocationContext *LCtx,
334 SVal getSVal(const Stmt *S, const LocationContext *LCtx) const;
452 const LocationContext *LCtx,
711 return bindLoc(*L, V, LCtx); in bindLoc()
766 const LocationContext *LCtx) const{ in getSVal() argument
767 return Env.getSVal(EnvironmentEntry(Ex, LCtx), in getSVal()
773 const LocationContext *LCtx) const { in getSValAsScalarOrLoc() argument
[all …]
H A DExprEngine.h400 const LocationContext *LCtx,
406 const LocationContext *LCtx) { in processRegionChange() argument
407 return processRegionChanges(state, nullptr, MR, MR, LCtx, nullptr); in processRegionChange()
412 const LocationContext *LCtx, const char *NL,
607 const LocationContext *LCtx,
644 const LocationContext *LCtx, PointerEscapeKind Kind,
667 const LocationContext *LCtx);
706 const LocationContext *LCtx,
726 const Expr *E, ProgramStateRef State, const LocationContext *LCtx,
741 const Expr *E, ProgramStateRef State, const LocationContext *LCtx, in handleConstructionContext() argument
[all …]
H A DSValBuilder.h194 const LocationContext *LCtx,
198 return SymMgr.conjureSymbol(stmt, LCtx, type, visitCount, symbolTag);
202 const LocationContext *LCtx,
205 return SymMgr.conjureSymbol(expr, LCtx, visitCount, symbolTag);
222 const LocationContext *LCtx,
226 const LocationContext *LCtx,
230 const LocationContext *LCtx,
238 const LocationContext *LCtx,
246 const LocationContext *LCtx,
255 const LocationContext *LCtx,
/freebsd-13.1/contrib/llvm-project/clang/lib/StaticAnalyzer/Checkers/
H A DCXXSelfAssignmentChecker.cpp41 const auto *LCtx = C.getLocationContext(); in checkBeginFunction() local
42 const auto *MD = dyn_cast<CXXMethodDecl>(LCtx->getDecl()); in checkBeginFunction()
50 State->getSVal(SVB.getCXXThis(MD, LCtx->getStackFrame())); in checkBeginFunction()
51 auto Param = SVB.makeLoc(State->getRegion(MD->getParamDecl(0), LCtx)); in checkBeginFunction()
54 ProgramStateRef SelfAssignState = State->bindLoc(Param, ThisVal, LCtx); in checkBeginFunction()
64 ProgramStateRef NonSelfAssignState = State->bindLoc(Param, ParamVal, LCtx); in checkBeginFunction()
H A DSTLAlgorithmModeling.cpp111 const auto *LCtx = C.getLocationContext(); in Find() local
113 SVal RetVal = SVB.conjureSymbolVal(nullptr, CE, LCtx, C.blockCount()); in Find()
114 SVal Param = State->getSVal(CE->getArg(paramNum), LCtx); in Find()
116 auto StateFound = State->BindExpr(CE, LCtx, RetVal); in Find()
125 CE, LCtx, C.blockCount()); in Find()
138 Param = State->getSVal(CE->getArg(paramNum + 1), LCtx); in Find()
147 CE, LCtx, C.blockCount()); in Find()
163 auto StateNotFound = State->BindExpr(CE, LCtx, Param); in Find()
H A DCStringChecker.cpp887 SVal BufVal = state->getSVal(FirstBuf, LCtx); in IsFirstBufInBound()
889 SVal LengthVal = state->getSVal(Size, LCtx); in IsFirstBufInBound()
1341 State = State->BindExpr(CE, LCtx, CmpV); in evalMemcmp()
1473 state = state->BindExpr(CE, LCtx, result); in evalstrLengthCommon()
1915 state = state->BindExpr(CE, LCtx, Result); in evalStrcpyCommon()
1986 StSameBuf = StSameBuf->BindExpr(CE, LCtx, in evalStrcmpCommon()
2114 LCtx, in evalStrsep()
2117 LCtx); in evalStrsep()
2125 State = State->BindExpr(CE, LCtx, Result); in evalStrsep()
2155 SVal DstVal = State->getSVal(Dst, LCtx); in evalStdCopyCommon()
[all …]
H A DCheckObjCDealloc.cpp264 const LocationContext *LCtx = C.getLocationContext(); in checkBeginFunction() local
495 const LocationContext *LCtx = C.getLocationContext(); in diagnoseMissingReleases() local
623 const LocationContext *LCtx = C.getLocationContext(); in findPropertyOnDeallocatingInstance() local
626 const ObjCImplDecl *Container = getContainingObjCImpl(LCtx); in findPropertyOnDeallocatingInstance()
798 auto *MD = cast<ObjCMethodDecl>(LCtx->getDecl()); in getContainingObjCImpl()
978 auto *MD = dyn_cast<ObjCMethodDecl>(LCtx->getDecl()); in isInInstanceDealloc()
982 const ImplicitParamDecl *SelfDecl = LCtx->getSelfDecl(); in isInInstanceDealloc()
995 const LocationContext *LCtx = C.getLocationContext(); in instanceDeallocIsOnStack() local
997 while (LCtx) { in instanceDeallocIsOnStack()
998 if (isInInstanceDealloc(C, LCtx, InstanceValOut)) in instanceDeallocIsOnStack()
[all …]
H A DBuiltinFunctionChecker.cpp40 const LocationContext *LCtx = C.getLocationContext(); in evalCall() local
77 C.addTransition(state->BindExpr(CE, LCtx, Arg)); in evalCall()
98 C.addTransition(state->BindExpr(CE, LCtx, loc::MemRegionVal(R))); in evalCall()
126 C.addTransition(state->BindExpr(CE, LCtx, V)); in evalCall()
H A DUndefBranchChecker.cpp33 const LocationContext *LCtx; member
36 : St(std::move(S)), LCtx(L) {} in FindUndefExpr()
51 return St->getSVal(Ex, LCtx).isUndef(); in MatchesCriteria()
/freebsd-13.1/contrib/llvm-project/clang/lib/Analysis/
H A DAnalysisDeclContext.cpp506 for (const LocationContext *LCtx = this; LCtx; LCtx = LCtx->getParent()) { in dumpStack() local
507 switch (LCtx->getKind()) { in dumpStack()
511 if (const auto *D = dyn_cast<NamedDecl>(LCtx->getDecl())) in dumpStack()
515 if (const Stmt *S = cast<StackFrameContext>(LCtx)->getCallSite()) { in dumpStack()
522 if (const Decl *D = cast<BlockInvocationContext>(LCtx)->getDecl()) { in dumpStack()
544 for (const LocationContext *LCtx = this; LCtx; LCtx = LCtx->getParent()) { in printJson() local
547 switch (LCtx->getKind()) { in printJson()
551 if (const auto *D = dyn_cast<NamedDecl>(LCtx->getDecl())) in printJson()
557 if (const Stmt *S = cast<StackFrameContext>(LCtx)->getCallSite()) { in printJson()
575 printMoreInfoPerContext(LCtx); in printJson()
[all …]
/freebsd-13.1/contrib/llvm-project/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker/
H A DRetainCountDiagnostics.cpp173 const LocationContext *LCtx, in findArgIdxOfSymbol() argument
214 const LocationContext *LCtx, in generateDiagnosticsForCallLike() argument
222 SVal X = CurrSt->getSValAsScalarOrLoc(CE->getCallee(), LCtx); in generateDiagnosticsForCallLike()
241 Mgr.getObjCMethodCall(cast<ObjCMessageExpr>(S), CurrSt, LCtx); in generateDiagnosticsForCallLike()
256 Optional<CallEventRef<>> CE = Mgr.getCall(S, CurrSt, LCtx); in generateDiagnosticsForCallLike()
257 auto Idx = findArgIdxOfSymbol(CurrSt, LCtx, Sym, CE); in generateDiagnosticsForCallLike()
485 const LocationContext *LCtx = N->getLocationContext(); in VisitNode() local
511 isSynthesizedAccessor(LCtx->getStackFrame())) { in VisitNode()
512 S = LCtx->getStackFrame()->getCallSite(); in VisitNode()
540 generateDiagnosticsForCallLike(CurrSt, LCtx, CurrV, Sym, S, os); in VisitNode()
[all …]

123