[PATCH] D77991: [llvm][NFC] CallSite removal from inliner-related files

Mircea Trofin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 13 11:18:07 PDT 2020


mtrofin added inline comments.


================
Comment at: llvm/lib/CodeGen/SafeStack.cpp:324
       case Instruction::Invoke: {
-        ImmutableCallSite CS(I);
+        const InvokeInst &CS = *cast<InvokeInst>(I);
 
----------------
craig.topper wrote:
> Shouldn't this be CallBase? Instruction::Call uses this code too.
True, thanks for the catch!


================
Comment at: llvm/lib/Transforms/IPO/PartialInlining.cpp:310
+      return CI;
     else if (InvokeInst *II = dyn_cast<InvokeInst>(U))
+      return II;
----------------
craig.topper wrote:
> Since you're here anyway, drop the else
There's still the case of a CallBrInst. Rewrote as it could be simpler, though.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D77991/new/

https://reviews.llvm.org/D77991





More information about the llvm-commits mailing list