manmanren added a subscriber: manmanren.
manmanren added a comment.

Thanks for working on this! A few comments inline.

Manman


================
Comment at: lib/CodeGen/CodeGenFunction.cpp:1962
@@ +1961,3 @@
+    for (auto *U : I->users())
+      InstrsToRemove.push_back(cast<llvm::Instruction>(U));
+
----------------
Do we need to check if the user has been erased? I am not sure if the same 
instruction can be pushed multiple times into InstrsToRemove.

================
Comment at: lib/CodeGen/CodeGenFunction.cpp:1979
@@ +1978,3 @@
+  if (auto *T = EntryBB->getTerminator())
+    T->eraseFromParent();
+
----------------
Is it possible that T has been erased in the above?


http://reviews.llvm.org/D15599



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to