[PATCH] D72382: [ArgPromotion] Extend search for SafeToUnconditionallyLoad indices to the blocks that must be executed upon entry into the function.

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 16 12:47:32 PST 2020


jdoerfert added a comment.

This should fix PR887: https://bugs.llvm.org/show_bug.cgi?id=887
Please verify that and include the test case from there. We should mention it in the commit message and close the bug if it works.

---

This should also fix PR42039: https://bugs.llvm.org/show_bug.cgi?id=42039
Please verify that and include the test case from there. We should mention it in the commit message and close the bug if it works.

In D72382#1824701 <https://reviews.llvm.org/D72382#1824701>, @mgudim wrote:

> @jdoerfert I updated the patch as you suggested. Also, I added your example as a test.


I don't see the example.



================
Comment at: llvm/lib/Transforms/IPO/ArgumentPromotion.cpp:637
+    return PDT;
+  };
+  MustBeExecutedContextExplorer Explorer(true, LIGetter, PDTGetter);
----------------
I think this is correct but it can be expensive. Since this runs by default in O3 you might want to verify the compile time impact and potentially put the construction under a flag.


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

https://reviews.llvm.org/D72382





More information about the llvm-commits mailing list