[PATCH] D78538: [llvm][NFC][CallSite] Remove CallSite from DeadArgumentElimination
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 20 23:18:19 PDT 2020
craig.topper added inline comments.
================
Comment at: llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp:567
// If this use is anything other than a call site, the function is alive.
- const Instruction *TheCall = CS.getInstruction();
- if (!TheCall) { // Not a direct call site?
+ if (!CB) { // Not a direct call site?
MarkLive(F);
----------------
I don't understand why this block exists. We already returned if it wasn't a callsite.
================
Comment at: llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp:875
while (!F->use_empty()) {
- CallSite CS(F->user_back());
- Instruction *Call = CS.getInstruction();
+ CallBase *CB = dyn_cast<CallBase>(F->user_back());
----------------
This should be a cast I think.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78538/new/
https://reviews.llvm.org/D78538
More information about the llvm-commits
mailing list