summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/ARM/fast-isel-redefinition.ll
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2011-04-29 21:22:56 +0000
committerEli Friedman <eli.friedman@gmail.com>2011-04-29 21:22:56 +0000
commit86caced370891a7874eb802c0a292a0a1e3244a2 (patch)
treee38bdda936da560121b1593c2ff84bacef5aac52 /llvm/test/CodeGen/ARM/fast-isel-redefinition.ll
parentf9e74104686126fd72228c4e489269d56ff1b54e (diff)
downloadbcm5719-llvm-86caced370891a7874eb802c0a292a0a1e3244a2.tar.gz
bcm5719-llvm-86caced370891a7874eb802c0a292a0a1e3244a2.zip
Re-committing r130454, which does not in fact break anything.
Fix a rather obscure crash caused by ARM fast-isel generating code which redefines a register. rdar://problem/9338332 . llvm-svn: 130539
Diffstat (limited to 'llvm/test/CodeGen/ARM/fast-isel-redefinition.ll')
-rw-r--r--llvm/test/CodeGen/ARM/fast-isel-redefinition.ll11
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/ARM/fast-isel-redefinition.ll b/llvm/test/CodeGen/ARM/fast-isel-redefinition.ll
new file mode 100644
index 00000000000..262432f807a
--- /dev/null
+++ b/llvm/test/CodeGen/ARM/fast-isel-redefinition.ll
@@ -0,0 +1,11 @@
+; RUN: llc -O0 -regalloc=linearscan | grep "ldr r0"
+; This isn't exactly a useful set of command-line options, but check that it
+; doesn't crash. (It was crashing because a register was getting redefined.)
+
+target triple = "thumbv7-apple-macosx10.6.7"
+
+define i32 @f(i32* %x) nounwind ssp {
+ %y = getelementptr inbounds i32* %x, i32 5000
+ %tmp103 = load i32* %y, align 4
+ ret i32 %tmp103
+}
OpenPOWER on IntegriCloud