[PATCH] D66651: Annotate return values of allocation functions with dereferenceable_or_null
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 27 12:14:36 PDT 2019
jdoerfert accepted this revision.
jdoerfert added a comment.
This revision is now accepted and ready to land.
Last problem mentioned below. Otherwise, LGTM.
================
Comment at: lib/Transforms/InstCombine/InstCombineCalls.cpp:4187
+ return;
+ if (isMallocLikeFn(&Call, TLI) && Op0C) {
+ Call.addAttribute(AttributeList::ReturnIndex,
----------------
You cannot remove the `isNullValue()` check here and below, Op1C could be the reason we skipped the return above!
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66651/new/
https://reviews.llvm.org/D66651
More information about the llvm-commits
mailing list