summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorOliver Stannard <oliver.stannard@arm.com>2017-10-24 14:19:08 +0000
committerOliver Stannard <oliver.stannard@arm.com>2017-10-24 14:19:08 +0000
commit60da1ac8d3295256a56573b74c0a131958db1c82 (patch)
tree9713691e40a84e1ddf9f99b670c3ff0d8ca22069 /test
parentc89087d28c0e3ec89ffb8d25c6d364fd8527328d (diff)
[ARM] Error for invalid shift in memory operand
Report a diagnostic when we fail to parse a shift in a memory operand because the shift type is not an identifier. Without this, we were silently ignoring the whole instruction. Differential revision: https://reviews.llvm.org/D39237 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@316441 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/MC/ARM/diagnostics.s3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/MC/ARM/diagnostics.s b/test/MC/ARM/diagnostics.s
index 223dbab8735..92272f68da5 100644
--- a/test/MC/ARM/diagnostics.s
+++ b/test/MC/ARM/diagnostics.s
@@ -60,6 +60,7 @@
ldr r4, [r5, r6, ror #-1]
pld r4, [r5, r6, ror #32]
pld r4, [r5, r6, rrx #0]
+ ldr r4, [r5, r6, not_a_shift]
@ CHECK-ERRORS: error: shift amount must be an immediate
@ CHECK-ERRORS: str r1, [r2, r3, lsl #invalid]
@@ -89,6 +90,8 @@
@ CHECK-ERRORS: pld r4, [r5, r6, ror #32]
@ CHECK-ERRORS: error: ']' expected
@ CHECK-ERRORS: pld r4, [r5, r6, rrx #0]
+@ CHECK-ERRORS: error: illegal shift operator
+@ CHECK-ERRORS: ldr r4, [r5, r6, not_a_shift]
@ Out of range 16-bit immediate on BKPT
bkpt #65536