[llvm] [LLVM][OpenMPOpt] Fix a crash when associated function is nullptr (PR #66274)
Johannes Doerfert via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 14 12:45:29 PDT 2023
================
@@ -5028,7 +5028,9 @@ struct AAKernelInfoCallSite : AAKernelInfo {
const auto *AACE =
A.getAAFor<AACallEdges>(*this, getIRPosition(), DepClassTy::OPTIONAL);
if (!AACE || !AACE->getState().isValidState() || AACE->hasUnknownCallee()) {
- CheckCallee(getAssociatedFunction(), /*NumCallees=*/1);
+ Function *F = getAssociatedFunction();
+ if (F)
+ CheckCallee(getAssociatedFunction(), /*NumCallees=*/1);
----------------
jdoerfert wrote:
F
https://github.com/llvm/llvm-project/pull/66274
More information about the llvm-commits
mailing list