diff options
author | Evan Cheng <evan.cheng@apple.com> | 2009-07-20 21:16:08 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2009-07-20 21:16:08 +0000 |
commit | 33d0474bf5d5783cf9690bcab3eabd513d918fc5 (patch) | |
tree | 1e90132e03510635e78a7a6402e07534c37fcfe3 /test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll | |
parent | 4aebcb4f5f69e545da86f7482a19a6a3902a5f9f (diff) | |
download | external_llvm-33d0474bf5d5783cf9690bcab3eabd513d918fc5.zip external_llvm-33d0474bf5d5783cf9690bcab3eabd513d918fc5.tar.gz external_llvm-33d0474bf5d5783cf9690bcab3eabd513d918fc5.tar.bz2 |
Use TII->findCommutedOpIndices to find the commute operands (rather than guessing).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76472 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll')
-rw-r--r-- | test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll b/test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll new file mode 100644 index 0000000..3e18d29 --- /dev/null +++ b/test/CodeGen/Thumb/2009-07-20-TwoAddrBug.ll @@ -0,0 +1,11 @@ +; RUN: llvm-as < %s | llc -mtriple=thumbv6-apple-darwin10 + +@Time.2535 = external global i64 ; <i64*> [#uses=2] + +define arm_apcscc i64 @millisecs() nounwind { +entry: + %0 = load i64* @Time.2535, align 4 ; <i64> [#uses=2] + %1 = add i64 %0, 1 ; <i64> [#uses=1] + store i64 %1, i64* @Time.2535, align 4 + ret i64 %0 +} |