Home
last modified time | relevance | path

Searched refs:SizeExpr (Results 1 – 18 of 18) sorted by relevance

/llvm-project-15.0.7/clang-tools-extra/clang-tidy/bugprone/
H A DSuspiciousMemoryComparisonCheck.cpp19 static llvm::Optional<uint64_t> tryEvaluateSizeExpr(const Expr *SizeExpr, in tryEvaluateSizeExpr() argument
22 if (SizeExpr->EvaluateAsRValue(Result, Ctx)) in tryEvaluateSizeExpr()
42 const Expr *SizeExpr = CE->getArg(2); in check() local
43 assert(SizeExpr != nullptr && "Third argument of memcmp is mandatory."); in check()
44 llvm::Optional<uint64_t> ComparedBits = tryEvaluateSizeExpr(SizeExpr, Ctx); in check()
H A DNotNullTerminatedResultCheck.cpp621 auto SizeExpr = anyOf(SizeOfCharExpr, integerLiteral(equals(1))); in registerMatchers() local
626 hasAnyArgument(allOf(unless(SizeExpr), expr().bind(DestMallocExprName)))); in registerMatchers()
/llvm-project-15.0.7/clang/lib/AST/
H A DStmtIterator.cpp111 assert(VAPtr->SizeExpr); in GetDeclExpr()
112 return const_cast<Stmt*&>(VAPtr->SizeExpr); in GetDeclExpr()
H A DType.cpp197 ID.AddBoolean(SizeExpr != nullptr); in Profile()
198 if (SizeExpr) in Profile()
199 SizeExpr->Profile(ID, Context, true); in Profile()
208 Context(Context), SizeExpr((Stmt*) e), Brackets(brackets) {} in DependentSizedArrayType()
230 (SizeExpr ? toTypeDependence(SizeExpr->getDependence()) in DependentVectorType()
232 Context(Context), ElementType(ElementType), SizeExpr(SizeExpr), Loc(Loc) { in DependentVectorType()
242 SizeExpr->Profile(ID, Context, true); in Profile()
247 Expr *SizeExpr, SourceLocation loc) in DependentSizedExtVectorType() argument
251 (SizeExpr ? toTypeDependence(SizeExpr->getDependence()) in DependentSizedExtVectorType()
253 Context(Context), SizeExpr(SizeExpr), ElementType(ElementType), loc(loc) { in DependentSizedExtVectorType()
[all …]
H A DASTContext.cpp3515 const Expr *SizeExpr, in getConstantArrayType() argument
3523 if (SizeExpr && !SizeExpr->isInstantiationDependent()) in getConstantArrayType()
3524 SizeExpr = nullptr; in getConstantArrayType()
4040 ASTContext::getDependentVectorType(QualType VecType, Expr *SizeExpr, in getDependentVectorType() argument
4058 *this, VecType, QualType(), SizeExpr, AttrLoc, VecKind); in getDependentVectorType()
4067 QualType CanonTy = getDependentVectorType(CanonVecTy, SizeExpr, in getDependentVectorType()
4070 *this, VecType, CanonTy, SizeExpr, AttrLoc, VecKind); in getDependentVectorType()
4111 Expr *SizeExpr, in getDependentSizedExtVectorType() argument
4115 SizeExpr); in getDependentSizedExtVectorType()
4126 SizeExpr, AttrLoc); in getDependentSizedExtVectorType()
[all …]
/llvm-project-15.0.7/clang/lib/StaticAnalyzer/Checkers/
H A DCheckPlacementNew.cpp81 const Expr *SizeExpr = *NE->getArraySize(); in getExtentSizeOfNewTarget() local
82 SVal ElementCount = C.getSVal(SizeExpr); in getExtentSizeOfNewTarget()
/llvm-project-15.0.7/clang/include/clang/AST/
H A DType.h3110 Stmt *SizeExpr;
3119 SizeExpr((Stmt*) e), Brackets(brackets) {}
3127 return (Expr*) SizeExpr;
3169 Stmt *SizeExpr;
3184 return (Expr*) SizeExpr;
3265 Expr *SizeExpr;
3276 Expr *getSizeExpr() const { return SizeExpr; }
3292 QualType ElementType, Expr *SizeExpr);
3385 Expr *SizeExpr;
3389 QualType CanonType, Expr *SizeExpr,
[all …]
H A DASTContext.h1471 const Expr *SizeExpr,
1511 QualType getDependentVectorType(QualType VectorType, Expr *SizeExpr,
1527 Expr *SizeExpr,
/llvm-project-15.0.7/clang/lib/CodeGen/
H A DCGDebugInfo.h390 void registerVLASizeExpression(QualType Ty, llvm::Metadata *SizeExpr) { in registerVLASizeExpression() argument
391 SizeExprCache[Ty] = SizeExpr; in registerVLASizeExpression()
H A DCGDebugInfo.cpp2991 auto SizeExpr = SizeExprCache.find(QTy); in CreateType() local
2992 if (SizeExpr != SizeExprCache.end()) in CreateType()
2994 SizeExpr->getSecond() /*count*/, nullptr /*lowerBound*/, in CreateType()
/llvm-project-15.0.7/clang/lib/Sema/
H A DSemaType.cpp2618 QualType Sema::BuildVectorType(QualType CurType, Expr *SizeExpr, in BuildVectorType() argument
2630 if (SizeExpr->isTypeDependent() || SizeExpr->isValueDependent()) in BuildVectorType()
2631 return Context.getDependentVectorType(CurType, SizeExpr, AttrLoc, in BuildVectorType()
2638 << SizeExpr->getSourceRange(); in BuildVectorType()
2650 << SizeExpr->getSourceRange() << "vector"; in BuildVectorType()
2658 << SizeExpr->getSourceRange() << "vector"; in BuildVectorType()
2664 << SizeExpr->getSourceRange(); in BuildVectorType()
2670 << SizeExpr->getSourceRange() << "vector"; in BuildVectorType()
7888 Expr *SizeExpr = Attr.getArgAsExpr(0); in HandleVectorSizeAttr() local
7889 QualType T = S.BuildVectorType(CurType, SizeExpr, Attr.getLoc()); in HandleVectorSizeAttr()
[all …]
H A DTreeTransform.h817 Expr *SizeExpr,
829 Expr *SizeExpr,
850 Expr *SizeExpr,
861 Expr *SizeExpr,
896 Expr *SizeExpr,
14528 Expr *SizeExpr, in RebuildArrayType() argument
14531 if (SizeExpr || !Size) in RebuildArrayType()
14564 Expr *SizeExpr, in RebuildConstantArrayType() argument
14585 Expr *SizeExpr, in RebuildVariableArrayType() argument
14589 SizeExpr, in RebuildVariableArrayType()
[all …]
H A DSemaDeclAttr.cpp834 const Expr *SizeExpr = AL.getArgAsExpr(0); in handleAllocSizeAttr() local
837 if (!checkPositiveIntArgument(S, AL, SizeExpr, SizeArgNoVal, /*Idx=*/1)) in handleAllocSizeAttr()
H A DSemaChecking.cpp15867 const Expr *SizeExpr = dyn_cast<IntegerLiteral>(CTL.getSizeExpr()); in IsTailPaddedMemberArray() local
15868 if (!SizeExpr || SizeExpr->getExprLoc().isMacroID()) in IsTailPaddedMemberArray()
H A DSemaOpenMP.cpp16683 for (Expr *SizeExpr : SizeExprs) { in ActOnOpenMPSizesClause()
16685 SizeExpr, OMPC_sizes, /*StrictlyPositive=*/true); in ActOnOpenMPSizesClause()
/llvm-project-15.0.7/bolt/lib/Core/
H A DBinaryEmitter.cpp376 const MCExpr *SizeExpr = MCBinaryExpr::createSub( in emitFunction() local
379 Streamer.emitELFSize(StartSymbol, SizeExpr); in emitFunction()
/llvm-project-15.0.7/clang/lib/StaticAnalyzer/Core/
H A DExprEngineCXX.cpp1173 Expr *SizeExpr = FieldForCapture->getCapturedVLAType()->getSizeExpr(); in VisitLambdaExpr() local
1174 InitVal = State->getSVal(SizeExpr, LocCtxt); in VisitLambdaExpr()
H A DExprEngineCallAndReturn.cpp753 if (const Expr *SizeExpr = CNE->getArraySize().value_or(nullptr)) { in bindReturnValue() local
754 ElementCount = State->getSVal(SizeExpr, LCtx); in bindReturnValue()