aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-02-27 21:59:31 +0000
committerChris Lattner <sabre@nondot.org>2003-02-27 21:59:31 +0000
commitda336622be90ee40fa5942d6da1dccdf90193021 (patch)
tree8990c8e44b60626404a1cbe21e41dce81a1d9f20
parent5a8a2912d506a55010a44b0dc6aabc178ce34ef1 (diff)
New testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5657 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/Transforms/LICM/2003-02-27-StoreSinkPHIs.ll13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/Transforms/LICM/2003-02-27-StoreSinkPHIs.ll b/test/Transforms/LICM/2003-02-27-StoreSinkPHIs.ll
new file mode 100644
index 0000000000..18193e1617
--- /dev/null
+++ b/test/Transforms/LICM/2003-02-27-StoreSinkPHIs.ll
@@ -0,0 +1,13 @@
+; LICM is adding stores before phi nodes. bad.
+
+; RUN: as < %s | opt -licm
+
+bool %test(bool %c) {
+ br bool %c, label %Loop, label %Out
+Loop:
+ store int 0, int* null
+ br bool %c, label %Loop, label %Out
+Out:
+ %X = phi bool [%c, %0], [true, %Loop]
+ ret bool %X
+}