[PATCH] D43729: [CallSiteSplitting] properly split musttail calls

Jun Bum Lim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 27 13:37:10 PST 2018


junbuml added a comment.

LGTM. 
I want to let Florian also review this as well.



================
Comment at: lib/Transforms/Scalar/CallSiteSplitting.cpp:212
 
-/// Return true if the CS is split into its new predecessors.
+static Instruction *cloneInstruction(Instruction *I, Instruction *Before,
+                                     Value *V) {
----------------
Since this is only for Return/BitCast for musttail, it will be good to name it more specifically. Something like cloneReturnInstForMustTail ? 


================
Comment at: lib/Transforms/Scalar/CallSiteSplitting.cpp:273
+      V = cloneInstruction(BCI, TI, V);
+      DEBUG(dbgs() << "        " << *V << " into\n");
+    }
----------------
It would be better if you can clean up  DEBUG little bit more. I think DEBUG only for BitCast and Return cloned is good enough.


https://reviews.llvm.org/D43729





More information about the llvm-commits mailing list