[PATCH] D21007: DSE: Don't remove stores made live by a call which unwinds.

Chad Rosier via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 21 11:16:22 PDT 2016


mcrosier added a comment.

The mechanical changes to deal with the iterators LGTM.  I'll defer to Hal or someone else to approve the changes to remove stores made live by a call which unwinds.


================
Comment at: lib/Transforms/Scalar/DeadStoreElimination.cpp:90
@@ -93,2 +89,3 @@
 }
 
+static void
----------------
Should we keep the comments from line 54?

================
Comment at: lib/Transforms/Scalar/DeadStoreElimination.cpp:837
@@ -757,1 +836,3 @@
 
+    size_t CurInstNumber = InstrIndex++;
+    InstrOrdering.insert(std::make_pair(Inst, CurInstNumber));
----------------
pre-increment InstrIndex.

================
Comment at: lib/Transforms/Scalar/DeadStoreElimination.cpp:892
@@ +891,3 @@
+      size_t DepIndex = InstrOrdering.lookup(DepWrite);
+      assert(DepIndex && "Unexpected instruction");
+      if (DepIndex <= LastThrowingInstIndex) {
----------------
Space between 'assert' and right paren.

Perhaps, a clang-format?


http://reviews.llvm.org/D21007





More information about the llvm-commits mailing list