[PATCH] D40670: Let Alloca treated as nonnull for any alloca addr space value
Stanislav Mekhanoshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 30 13:45:47 PST 2017
rampitec accepted this revision.
rampitec added a comment.
This revision is now accepted and ready to land.
LGTM
================
Comment at: lib/Analysis/ValueTracking.cpp:1864
+ // Alloca never returns null.
+ if (isa<AllocaInst>(V))
return true;
----------------
arsenm wrote:
> rampitec wrote:
> > What was the original comment about? Is there a chance alloca can be used for malloc?
> No, the lifetime of the alloca ends when the function does which wouldn't work for malloc
So I assume the check and comment were misleading.
https://reviews.llvm.org/D40670
More information about the llvm-commits
mailing list