diff options
author | Andrew Trick <atrick@apple.com> | 2011-04-23 03:55:32 +0000 |
---|---|---|
committer | Andrew Trick <atrick@apple.com> | 2011-04-23 03:55:32 +0000 |
commit | 0ed5778a1ee9da1de3fcc65608051fe1581481cd (patch) | |
tree | 9fa0553c93476e04ca96e3a2679f934c2a36798e /llvm/test/CodeGen/Thumb2/thumb2-sub5.ll | |
parent | 3260c9df4eaefa03bf9d4d9cf8ec593951d8fbab (diff) | |
download | bcm5719-llvm-0ed5778a1ee9da1de3fcc65608051fe1581481cd.tar.gz bcm5719-llvm-0ed5778a1ee9da1de3fcc65608051fe1581481cd.zip |
Thumb2 and ARM add/subtract with carry fixes.
Fixes Thumb2 ADCS and SBCS lowering: <rdar://problem/9275821>.
t2ADCS/t2SBCS are now pseudo instructions, consistent with ARM, so the
assembly printer correctly prints the 's' suffix.
Fixes Thumb2 adde -> SBC matching to check for live/dead carry flags.
Fixes the internal ARM machine opcode mnemonic for ADCS/SBCS.
Fixes ARM SBC lowering to check for live carry (potential bug).
llvm-svn: 130048
Diffstat (limited to 'llvm/test/CodeGen/Thumb2/thumb2-sub5.ll')
-rw-r--r-- | llvm/test/CodeGen/Thumb2/thumb2-sub5.ll | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/llvm/test/CodeGen/Thumb2/thumb2-sub5.ll b/llvm/test/CodeGen/Thumb2/thumb2-sub5.ll index c3b56bc09c8..6edd789beec 100644 --- a/llvm/test/CodeGen/Thumb2/thumb2-sub5.ll +++ b/llvm/test/CodeGen/Thumb2/thumb2-sub5.ll @@ -1,9 +1,10 @@ -; RUN: llc < %s -march=thumb -mattr=+thumb2 | FileCheck %s +; RUN: llc < %s -march=thumb -mattr=+thumb2 -mattr=+32bit | FileCheck %s define i64 @f1(i64 %a, i64 %b) { ; CHECK: f1: -; CHECK: subs r0, r0, r2 -; CHECK: sbcs r1, r3 +; CHECK: subs.w r0, r0, r2 +; To test dead_carry, +32bit prevents sbc conveting to 16-bit sbcs +; CHECK: sbc.w r1, r1, r3 %tmp = sub i64 %a, %b ret i64 %tmp } |