Home
last modified time | relevance | path

Searched refs:ConcreteInt (Results 1 – 25 of 33) sorted by relevance

12

/openbsd-src/gnu/llvm/clang/include/clang/StaticAnalyzer/Core/PathSensitive/
H A DSValBuilder.h260 return nonloc::ConcreteInt(BasicVals.getValue(0, ArrayIndexTy)); in makeZeroArrayIndex()
264 return nonloc::ConcreteInt(BasicVals.getValue(idx, ArrayIndexTy)); in makeArrayIndex()
269 nonloc::ConcreteInt makeIntVal(const IntegerLiteral* integer) { in makeIntVal()
270 return nonloc::ConcreteInt( in makeIntVal()
275 nonloc::ConcreteInt makeBoolVal(const ObjCBoolLiteralExpr *boolean) { in makeBoolVal()
279 nonloc::ConcreteInt makeBoolVal(const CXXBoolLiteralExpr *boolean);
281 nonloc::ConcreteInt makeIntVal(const llvm::APSInt& integer) { in makeIntVal()
282 return nonloc::ConcreteInt(BasicVals.getValue(integer)); in makeIntVal()
285 loc::ConcreteInt makeIntLocVal(const llvm::APSInt &integer) { in makeIntLocVal()
286 return loc::ConcreteInt(BasicVals.getValue(integer)); in makeIntLocVal()
[all …]
H A DSVals.def59 LOC_SVAL(ConcreteInt, Loc)
64 NONLOC_SVAL(ConcreteInt, NonLoc)
H A DSVals.h329 class ConcreteInt : public NonLoc {
331 explicit ConcreteInt(const llvm::APSInt& V) : NonLoc(ConcreteIntKind, &V) {} in ConcreteInt() function
539 class ConcreteInt : public Loc {
541 explicit ConcreteInt(const llvm::APSInt& V) : Loc(ConcreteIntKind, &V) {} in ConcreteInt() function
/openbsd-src/gnu/llvm/clang/lib/StaticAnalyzer/Core/
H A DSVals.cpp113 if (auto CI = getAs<nonloc::ConcreteInt>()) in getAsInteger()
115 if (auto CI = getAs<loc::ConcreteInt>()) in getAsInteger()
145 template <class ConcreteInt> QualType VisitConcreteInt(ConcreteInt CI) { in VisitConcreteInt()
151 QualType VisitLocConcreteInt(loc::ConcreteInt CI) { in VisitLocConcreteInt()
154 QualType VisitNonLocConcreteInt(nonloc::ConcreteInt CI) { in VisitNonLocConcreteInt()
250 return getAs<nonloc::ConcreteInt>() || getAs<loc::ConcreteInt>(); in isConstant()
254 if (std::optional<loc::ConcreteInt> LV = getAs<loc::ConcreteInt>()) in isConstant()
256 if (std::optional<nonloc::ConcreteInt> NV = getAs<nonloc::ConcreteInt>()) in isConstant()
300 const auto &Value = castAs<nonloc::ConcreteInt>().getValue(); in dumpToStream()
366 os << castAs<loc::ConcreteInt>().getValue().getZExtValue() << " (Loc)"; in dumpToStream()
H A DSimpleSValBuilder.cpp169 return nonloc::ConcreteInt(Result); in MakeSymIntVal()
225 nonloc::ConcreteInt(Bound), SVB.getConditionType()); in isInRelation()
303 return SVB.evalBinOpNN(State, Op, nonloc::ConcreteInt(LInt), in doRearrangeUnchecked()
304 nonloc::ConcreteInt(RInt), ResultTy) in doRearrangeUnchecked()
486 llvm::APSInt i = rhs.castAs<nonloc::ConcreteInt>().getValue(); in evalBinOpNN()
511 llvm::APSInt LHSValue = lhs.castAs<nonloc::ConcreteInt>().getValue(); in evalBinOpNN()
535 return nonloc::ConcreteInt(*Result); in evalBinOpNN()
669 rhs = nonloc::ConcreteInt(*newRHS); in evalBinOpNN()
832 auto L = lhs.castAs<loc::ConcreteInt>(); in evalBinOpLL()
847 if (std::optional<loc::ConcreteInt> rInt = rhs.getAs<loc::ConcreteInt>()) { in evalBinOpLL()
[all …]
H A DSValBuilder.cpp126 if (std::optional<nonloc::ConcreteInt> CI = in convertToArrayIndex()
127 val.getAs<nonloc::ConcreteInt>()) { in convertToArrayIndex()
136 nonloc::ConcreteInt SValBuilder::makeBoolVal(const CXXBoolLiteralExpr *boolean){ in makeBoolVal()
437 if (std::optional<nonloc::ConcreteInt> rInt = in makeSymExprValNN()
438 RHS.getAs<nonloc::ConcreteInt>()) in makeSymExprValNN()
442 if (std::optional<nonloc::ConcreteInt> lInt = in makeSymExprValNN()
443 LHS.getAs<nonloc::ConcreteInt>()) in makeSymExprValNN()
452 return makeIntVal(-X.castAs<nonloc::ConcreteInt>().getValue()); in evalMinus()
464 return makeIntVal(~X.castAs<nonloc::ConcreteInt>().getValue()); in evalComplement()
526 if (auto RV = rhs.getAs<loc::ConcreteInt>()) { in evalBinOp()
[all …]
H A DStore.cpp463 if (Base.isUnknownOrUndef() || isa<loc::ConcreteInt>(Base)) in getLValueElement()
492 if (!isa<nonloc::ConcreteInt>(BaseIdx)) in getLValueElement()
496 BaseIdx.castAs<nonloc::ConcreteInt>().getValue(); in getLValueElement()
501 if (!isa<nonloc::ConcreteInt>(Offset)) { in getLValueElement()
509 const llvm::APSInt& OffI = Offset.castAs<nonloc::ConcreteInt>().getValue(); in getLValueElement()
513 nonloc::ConcreteInt NewIdx(svalBuilder.getBasicValueFactory().getValue(BaseIdxI + in getLValueElement()
H A DSimpleConstraintManager.cpp78 bool b = Cond.castAs<nonloc::ConcreteInt>().getValue() != 0; in assumeAux()
123 const llvm::APSInt &IntVal = Value.castAs<nonloc::ConcreteInt>().getValue(); in assumeInclusiveRangeInternal()
H A DProgramState.cpp292 return loc::ConcreteInt(NewV); in getSVal()
294 return nonloc::ConcreteInt(NewV); in getSVal()
334 nonloc::ConcreteInt Min(BVF.getMinValue(indexTy)); in assumeInBoundDual()
H A DRegionStore.cpp866 if (std::optional<nonloc::ConcreteInt> ExtentCI = in collectSubRegionBindings()
867 Extent.getAs<nonloc::ConcreteInt>()) { in collectSubRegionBindings()
1380 if (isa<loc::ConcreteInt>(Array)) in ArrayToPointer()
1406 if (L.getAs<loc::ConcreteInt>()) { in getBinding()
1708 if (auto CI = V.getAs<nonloc::ConcreteInt>()) { in convertOffsetsFromSvalToUnsigneds()
1937 if (const auto CI = R->getIndex().getAs<nonloc::ConcreteInt>()) { in getBindingForElement()
2377 if (L.getAs<loc::ConcreteInt>()) in bind()
H A DBugReporterVisitors.cpp236 if (auto CI = V->getAs<nonloc::ConcreteInt>()) in getConcreteIntegerValue()
1070 if (auto CI = V.getAs<nonloc::ConcreteInt>()) { in visitNodeInitial()
1303 if (isa<loc::ConcreteInt>(SI.Value)) { in showBRDiagnostics()
1306 } else if (auto CVal = SI.Value.getAs<nonloc::ConcreteInt>()) { in showBRDiagnostics()
1346 if (isa<loc::ConcreteInt>(SI.Value)) { in showBRParamDiagnostics()
1352 } else if (auto CI = SI.Value.getAs<nonloc::ConcreteInt>()) { in showBRParamDiagnostics()
1383 if (isa<loc::ConcreteInt>(SI.Value)) { in showBRDefaultDiagnostics()
1392 } else if (auto CV = SI.Value.getAs<nonloc::ConcreteInt>()) { in showBRDefaultDiagnostics()
/openbsd-src/gnu/llvm/clang/lib/StaticAnalyzer/Checkers/
H A DArrayBoundCheckerV2.cpp85 static std::pair<NonLoc, nonloc::ConcreteInt>
86 getSimplifiedOffsets(NonLoc offset, nonloc::ConcreteInt extent, in getSimplifiedOffsets()
98 return std::pair<NonLoc, nonloc::ConcreteInt>(offset, extent); in getSimplifiedOffsets()
114 return std::pair<NonLoc, nonloc::ConcreteInt>(offset, extent); in getSimplifiedOffsets()
148 if (auto ConcreteNV = NV->getAs<nonloc::ConcreteInt>()) { in checkLocation()
149 std::pair<NonLoc, nonloc::ConcreteInt> simplifiedOffsets = in checkLocation()
186 if (auto ConcreteSize = Size.getAs<nonloc::ConcreteInt>()) { in checkLocation()
187 std::pair<NonLoc, nonloc::ConcreteInt> simplifiedOffsets = in checkLocation()
H A DDebugIteratorModeling.cpp107 }, nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(0)))); in analyzerIteratorPosition()
115 }, loc::ConcreteInt(BVF.getValue(llvm::APSInt::get(0)))); in analyzerIteratorContainer()
123 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get((P->isValid())))); in analyzerIteratorValidity()
124 }, nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(0)))); in analyzerIteratorValidity()
H A DIterator.cpp239 const auto IntDistOp = Distance.getAs<nonloc::ConcreteInt>(); in advancePosition()
244 nonloc::ConcreteInt IntDist = *IntDistOp; in advancePosition()
247 IntDist = nonloc::ConcreteInt(BVF.getValue(-IntDist.getValue())); in advancePosition()
279 nonloc::ConcreteInt(Max), SVB.getConditionType()); in assumeNoOverflow()
289 nonloc::ConcreteInt(Min), SVB.getConditionType()); in assumeNoOverflow()
H A DReturnPointerRangeChecker.cpp92 const auto ConcreteElementCount = ElementCount.getAs<nonloc::ConcreteInt>(); in checkPreStmt()
93 const auto ConcreteIdx = Idx.getAs<nonloc::ConcreteInt>(); in checkPreStmt()
H A DIteratorRangeChecker.cpp138 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1)))); in checkPreCall()
212 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1)))); in verifyIncrement()
218 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1)))); in verifyDecrement()
301 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(0))), in isZero()
H A DMmapWriteExecChecker.cpp51 auto ProtLoc = ProtVal.castAs<nonloc::ConcreteInt>(); in checkPreCall()
H A DContainerModeling.cpp439 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1))), in handlePushBack()
468 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1))), in handlePopBack()
513 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1))), in handlePushFront()
550 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1))), in handlePopFront()
675 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1))), in handleEraseAfter()
1027 const auto DiffInt = Diff.getAs<nonloc::ConcreteInt>(); in rebaseSymbol()
H A DCheckPlacementNew.cpp107 const auto SizeOfTargetCI = SizeOfTarget.getAs<nonloc::ConcreteInt>(); in checkPlaceCapacityIsSufficient()
110 const auto SizeOfPlaceCI = SizeOfPlace.getAs<nonloc::ConcreteInt>(); in checkPlaceCapacityIsSufficient()
H A DDebugContainerModeling.cpp116 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(0)))); in analyzerContainerDataField()
H A DIteratorModeling.cpp511 if (const auto TruthVal = RetVal.getAs<nonloc::ConcreteInt>()) { in processComparison()
550 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1)))); in handleIncrement()
576 nonloc::ConcreteInt(BVF.getValue(llvm::APSInt::get(1)))); in handleDecrement()
H A DBasicObjCFoundationChecks.cpp446 std::optional<nonloc::ConcreteInt> V = in checkPreStmt()
447 dyn_cast<nonloc::ConcreteInt>(TheTypeVal); in checkPreStmt()
759 if (isa<loc::ConcreteInt>(msg.getArgSVal(I))) in checkPreObjCMessage()
/openbsd-src/gnu/llvm/clang/include/clang/StaticAnalyzer/Checkers/
H A DSValExplainer.h79 std::string VisitLocConcreteInt(loc::ConcreteInt V) { in VisitLocConcreteInt()
91 std::string VisitNonLocConcreteInt(nonloc::ConcreteInt V) { in VisitNonLocConcreteInt()
198 if (auto I = R->getIndex().getAs<nonloc::ConcreteInt>()) in VisitElementRegion()
/openbsd-src/gnu/llvm/clang/lib/StaticAnalyzer/Checkers/MPI-Checker/
H A DMPIChecker.cpp168 ElementCount.castAs<nonloc::ConcreteInt>().getValue(); in allRegionsUsedByWait()
/openbsd-src/gnu/llvm/clang/lib/StaticAnalyzer/Checkers/UninitializedObject/
H A DUninitializedPointee.cpp146 if (V.isUnknown() || isa<loc::ConcreteInt>(V)) { in isDereferencableUninit()

12