diff options
author | Chris Lattner <sabre@nondot.org> | 2010-08-29 18:22:25 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-08-29 18:22:25 +0000 |
commit | 0de5cad74d8d2987b92b8d76af3f1eab988b3c7b (patch) | |
tree | eb94a7c72f1cad30c16c868f9f6dde5213279dfc /test/Transforms/LICM | |
parent | d9a5daeb7719c83136c0dc43d6ef732402d1a1b5 (diff) | |
download | external_llvm-0de5cad74d8d2987b92b8d76af3f1eab988b3c7b.zip external_llvm-0de5cad74d8d2987b92b8d76af3f1eab988b3c7b.tar.gz external_llvm-0de5cad74d8d2987b92b8d76af3f1eab988b3c7b.tar.bz2 |
LICM does get dead instructions input to it. Instead of sinking them
out of loops, just delete them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112451 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/LICM')
-rw-r--r-- | test/Transforms/LICM/sinking.ll | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/Transforms/LICM/sinking.ll b/test/Transforms/LICM/sinking.ll index 11112eb..68e4b64 100644 --- a/test/Transforms/LICM/sinking.ll +++ b/test/Transforms/LICM/sinking.ll @@ -233,3 +233,17 @@ Out: ; preds = %Loop ; CHECK-NEXT: ret i32 %tmp.6 } +; Should delete, not sink, dead instructions. +define void @test11() { + br label %Loop +Loop: + %dead = getelementptr %Ty* @X2, i64 0, i32 0 + br i1 false, label %Loop, label %Out +Out: + ret void +; CHECK: @test11 +; CHECK: Out: +; CHECK-NEXT: ret void +} + + |