summaryrefslogtreecommitdiff
path: root/test/MC
diff options
context:
space:
mode:
authorJim Grosbach <grosbach@apple.com>2011-10-26 22:22:01 +0000
committerJim Grosbach <grosbach@apple.com>2011-10-26 22:22:01 +0000
commita581328ceb4c9db165d79a4dabd6b28db799d70f (patch)
tree0d78e3ea80da0be3bf543d6a147ea08877d90a5a /test/MC
parent2a1286ed58bd02a5cffefbf25e45d9f6b61249c8 (diff)
downloadllvm-a581328ceb4c9db165d79a4dabd6b28db799d70f.tar.gz
llvm-a581328ceb4c9db165d79a4dabd6b28db799d70f.tar.bz2
llvm-a581328ceb4c9db165d79a4dabd6b28db799d70f.tar.xz
Thumb2 ldr pc-relative encoding fixes.
We were parsing label references to the i12 encoding, which isn't right. They need to go to the pci variant instead. More of rdar://10348687 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143068 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/MC')
-rw-r--r--test/MC/ARM/basic-thumb2-instructions.s19
1 files changed, 11 insertions, 8 deletions
diff --git a/test/MC/ARM/basic-thumb2-instructions.s b/test/MC/ARM/basic-thumb2-instructions.s
index 68815dab01..4927e58e5b 100644
--- a/test/MC/ARM/basic-thumb2-instructions.s
+++ b/test/MC/ARM/basic-thumb2-instructions.s
@@ -638,9 +638,12 @@ _func:
@ LDR(literal)
@------------------------------------------------------------------------------
ldr.w r5, _foo
+ ldr lr, (_strcmp-4)
@ CHECK: ldr.w r5, _foo @ encoding: [0x5f'A',0xf8'A',A,0x50'A']
- @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
+@ CHECK: @ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
+@ CHECK: ldr.w lr, _strcmp-4 @ encoding: [0x5f'A',0xf8'A',A,0xe0'A']
+@ CHECK: @ fixup A - offset: 0, value: _strcmp-4, kind: fixup_t2_ldst_pcrel_12
@------------------------------------------------------------------------------
@@ -813,7 +816,7 @@ _func:
@------------------------------------------------------------------------------
ldrh r5, _bar
-@ CHECK: ldrh.w r5, _bar @ encoding: [0xbf'A',0xf8'A',A,0x50'A']
+@ CHECK: ldrh.w r5, _bar @ encoding: [0x3f'A',0xf8'A',A,0x50'A']
@ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
@@ -882,7 +885,7 @@ _func:
@------------------------------------------------------------------------------
ldrsb r5, _bar
-@ CHECK: ldrsb.w r5, _bar @ encoding: [0x9f'A',0xf9'A',A,0x50'A']
+@ CHECK: ldrsb.w r5, _bar @ encoding: [0x1f'A',0xf9'A',A,0x50'A']
@ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
@@ -951,7 +954,7 @@ _func:
@------------------------------------------------------------------------------
ldrsh r5, _bar
-@ CHECK: ldrsh.w r5, _bar @ encoding: [0xbf'A',0xf9'A',A,0x50'A']
+@ CHECK: ldrsh.w r5, _bar @ encoding: [0x3f'A',0xf9'A',A,0x50'A']
@ CHECK: @ fixup A - offset: 0, value: _bar, kind: fixup_t2_ldst_pcrel_12
@ TEMPORARILY DISABLED:
@@ -1354,9 +1357,9 @@ _func:
@------------------------------------------------------------------------------
@ PLD(literal)
@------------------------------------------------------------------------------
- pld _foo
+@ pld _foo
-@ CHECK: pld _foo @ encoding: [0x9f'A',0xf8'A',A,0xf0'A']
+@ FIXME: pld _foo @ encoding: [0x9f'A',0xf8'A',A,0xf0'A']
@ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12
@@ -1396,10 +1399,10 @@ _func:
@------------------------------------------------------------------------------
@ PLI(literal)
@------------------------------------------------------------------------------
- pli _foo
+@ pli _foo
-@ CHECK: pli _foo @ encoding: [0x9f'A',0xf9'A',A,0xf0'A']
+@ FIXME: pli _foo @ encoding: [0x9f'A',0xf9'A',A,0xf0'A']
@ fixup A - offset: 0, value: _foo, kind: fixup_t2_ldst_pcrel_12