[PATCH] D152197: Fix static analyzer bugs with null pointer dereferences in CheckSizelessVectorOperands()
Soumi Manna via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jun 6 20:14:39 PDT 2023
Manna marked an inline comment as done.
Manna added inline comments.
================
Comment at: clang/lib/Sema/SemaExpr.cpp:11148
if (LHSType->isVLSTBuiltinType() && RHSType->isVLSTBuiltinType() &&
Context.getBuiltinVectorTypeInfo(LHSBuiltinTy).EC !=
Context.getBuiltinVectorTypeInfo(RHSBuiltinTy).EC) {
----------------
erichkeane wrote:
> This is the only other use of htem, but the 1st part of the 'if' checks if these are builtin types.
Thanks for the comments. I have added nullptr checks for LHSBuiltinTy and RHSBuiltinTy before using them to getBuiltinVectorTypeInfo() which dereferences.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D152197/new/
https://reviews.llvm.org/D152197
More information about the cfe-commits
mailing list