[PATCH] D20638: [LIR] Fix mis-compilation with unwinding

Eli Friedman via llvm-commits llvm-commits at lists.llvm.org
Thu May 26 10:48:25 PDT 2016


eli.friedman added inline comments.

================
Comment at: lib/Transforms/Scalar/LoopIdiomRecognize.cpp:392
@@ +391,3 @@
+      return;
+    }
+
----------------
This check is in collectStores, which is run once per basic block... so this won't notice a call which throws in a different basic block ("for (...) { p[i] = 0; if (a) throwing_fn(); }"),

================
Comment at: test/Transforms/LoopIdiom/unwind.ll:18
@@ +17,3 @@
+  unreachable
+}
+
----------------
No reason to include the implementation of f in the testcase.


Repository:
  rL LLVM

http://reviews.llvm.org/D20638





More information about the llvm-commits mailing list