diff options
| author | Scott Douglass <sdouglass@arm.com> | 2015-07-09 14:13:55 +0000 |
|---|---|---|
| committer | Scott Douglass <sdouglass@arm.com> | 2015-07-09 14:13:55 +0000 |
| commit | 8143bc25ee576eb4b1cc923ede42281f1140bfb3 (patch) | |
| tree | bbf8345b25ea81b9698b87cd5129e540f8ed1c32 /llvm/test | |
| parent | 2740a6372514329605d0d43ddbb4a8399d48ed29 (diff) | |
| download | bcm5719-llvm-8143bc25ee576eb4b1cc923ede42281f1140bfb3.tar.gz bcm5719-llvm-8143bc25ee576eb4b1cc923ede42281f1140bfb3.zip | |
[ARM] Thumb1 3 to 2 operand convertion for commutative operations
Differential Revision: http://reviews.llvm.org/D11057
llvm-svn: 241802
Diffstat (limited to 'llvm/test')
| -rw-r--r-- | llvm/test/MC/ARM/thumb2-narrow-dp.ll | 4 | ||||
| -rw-r--r-- | llvm/test/MC/ARM/thumb_rewrites.s | 15 |
2 files changed, 19 insertions, 0 deletions
diff --git a/llvm/test/MC/ARM/thumb2-narrow-dp.ll b/llvm/test/MC/ARM/thumb2-narrow-dp.ll index 42cf2979370..13bbd1ff754 100644 --- a/llvm/test/MC/ARM/thumb2-narrow-dp.ll +++ b/llvm/test/MC/ARM/thumb2-narrow-dp.ll @@ -67,8 +67,12 @@ // CHECK: add r3, r1 @ encoding: [0x0b,0x44] ADD r4, r4, pc // T2 // CHECK: add r4, pc @ encoding: [0x7c,0x44] + ADD r4, pc, r4 // T2 +// CHECK: add r4, pc @ encoding: [0x7c,0x44] ADD pc, pc, r2 // T2 // CHECK: add pc, r2 @ encoding: [0x97,0x44] + ADD pc, r2, pc // T2 +// CHECK: add pc, r2 @ encoding: [0x97,0x44] // ADD (SP plus immediate) A8.8.9 ADD sp, sp, #20 // T2 diff --git a/llvm/test/MC/ARM/thumb_rewrites.s b/llvm/test/MC/ARM/thumb_rewrites.s index b2ef83d4936..e9f03d6b9a5 100644 --- a/llvm/test/MC/ARM/thumb_rewrites.s +++ b/llvm/test/MC/ARM/thumb_rewrites.s @@ -15,6 +15,9 @@ add r0, r0, r8 @ CHECK: add r0, r8 @ encoding: [0x40,0x44] + add r1, r8, r1 +@ CHECK: add r1, r8 @ encoding: [0x41,0x44] + add sp, sp, r0 @ CHECK: add sp, r0 @ encoding: [0x85,0x44] @@ -52,12 +55,18 @@ sub sp, sp, #16 @ CHECK: sub sp, #16 @ encoding: [0x84,0xb0] + ands r0, r1, r0 +@ CHECK: ands r0, r1 @ encoding: [0x08,0x40] + ands r0, r0, r1 @ CHECK: ands r0, r1 @ encoding: [0x08,0x40] eors r0, r0, r1 @ CHECK: eors r0, r1 @ encoding: [0x48,0x40] + eors r0, r1, r0 +@ CHECK: eors r0, r1 @ encoding: [0x48,0x40] + lsls r0, r0, r1 @ CHECK: lsls r0, r1 @ encoding: [0x88,0x40] @@ -70,6 +79,9 @@ adcs r0, r0, r1 @ CHECK: adcs r0, r1 @ encoding: [0x48,0x41] + adcs r0, r1, r0 +@ CHECK: adcs r0, r1 @ encoding: [0x48,0x41] + sbcs r0, r0, r1 @ CHECK: sbcs r0, r1 @ encoding: [0x88,0x41] @@ -79,5 +91,8 @@ orrs r0, r0, r1 @ CHECK: orrs r0, r1 @ encoding: [0x08,0x43] + orrs r0, r1, r0 +@ CHECK: orrs r0, r1 @ encoding: [0x08,0x43] + bics r0, r0, r1 @ CHECK: bics r0, r1 @ encoding: [0x88,0x43] |

