[PATCH] D47237: [DSE] Calloc optimizations
Dávid Bolvanský via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 22 17:01:54 PDT 2018
xbolva00 added inline comments.
================
Comment at: lib/Analysis/MemoryLocation.cpp:24
+ CI->getAAMetadata(AATags);
+ // FIXME: add support to use other operands
+ Value *Op = CI->getOperand(0);
----------------
To add support for other ops, maybe extend function to
MemoryLocation::get(const CallInst *CI, const Value *Op)?
================
Comment at: lib/Transforms/Scalar/DeadStoreElimination.cpp:1108
+ return false;
+ if (!isStringFromCalloc(Dst, TLI))
+ return false;
----------------
eliminateNoopStore uses "isCallocLikeFn" (does it check if any of the arguments is zero?), but I believe I could not use it here. Suggestions?
Repository:
rL LLVM
https://reviews.llvm.org/D47237
More information about the llvm-commits
mailing list