diff options
author | Artyom Skrobov <Artyom.Skrobov@arm.com> | 2013-10-23 10:14:40 +0000 |
---|---|---|
committer | Artyom Skrobov <Artyom.Skrobov@arm.com> | 2013-10-23 10:14:40 +0000 |
commit | b161955ffbda5ccb5293e0c76ef982acb6ec6661 (patch) | |
tree | cd41ea9737b88f53f7bce2f6e15c8628071c19df /test/MC | |
parent | 2c6e1cf1dd4d0789118f9761e23885dda94296e1 (diff) | |
download | external_llvm-b161955ffbda5ccb5293e0c76ef982acb6ec6661.zip external_llvm-b161955ffbda5ccb5293e0c76ef982acb6ec6661.tar.gz external_llvm-b161955ffbda5ccb5293e0c76ef982acb6ec6661.tar.bz2 |
Make ARM hint ranges consistent, and add tests for these ranges
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193238 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/MC')
-rw-r--r-- | test/MC/ARM/basic-arm-instructions.s | 4 | ||||
-rw-r--r-- | test/MC/ARM/basic-thumb2-instructions.s | 10 | ||||
-rw-r--r-- | test/MC/ARM/invalid-hint-arm.s | 8 | ||||
-rw-r--r-- | test/MC/ARM/invalid-hint-thumb.s | 8 | ||||
-rw-r--r-- | test/MC/Disassembler/ARM/thumb2.txt | 8 |
5 files changed, 34 insertions, 4 deletions
diff --git a/test/MC/ARM/basic-arm-instructions.s b/test/MC/ARM/basic-arm-instructions.s index 636682f..aeec633 100644 --- a/test/MC/ARM/basic-arm-instructions.s +++ b/test/MC/ARM/basic-arm-instructions.s @@ -2928,7 +2928,7 @@ Lforward: hint #2 hint #1 hint #0 - hint #255 + hintgt #239 @ CHECK: wfe @ encoding: [0x02,0xf0,0x20,0xe3] @ CHECK: wfehi @ encoding: [0x02,0xf0,0x20,0x83] @@ -2941,4 +2941,4 @@ Lforward: @ CHECK: wfe @ encoding: [0x02,0xf0,0x20,0xe3] @ CHECK: yield @ encoding: [0x01,0xf0,0x20,0xe3] @ CHECK: nop @ encoding: [0x00,0xf0,0x20,0xe3] -@ CHECK: hint #255 @ encoding: [0xff,0xf0,0x20,0xe3] +@ CHECK: hintgt #239 @ encoding: [0xef,0xf0,0x20,0xc3] diff --git a/test/MC/ARM/basic-thumb2-instructions.s b/test/MC/ARM/basic-thumb2-instructions.s index eb5b614..fdb2225 100644 --- a/test/MC/ARM/basic-thumb2-instructions.s +++ b/test/MC/ARM/basic-thumb2-instructions.s @@ -3603,6 +3603,11 @@ _func: hint #1 hint #0 + itet lt + hintlt #15 + hintge #16 + hintlt #239 + @ CHECK: wfe @ encoding: [0x20,0xbf] @ CHECK: wfi @ encoding: [0x30,0xbf] @ CHECK: yield @ encoding: [0x10,0xbf] @@ -3621,6 +3626,11 @@ _func: @ CHECK: yield @ encoding: [0x10,0xbf] @ CHECK: nop @ encoding: [0x00,0xbf] +@ CHECK: itet lt @ encoding: [0xb6,0xbf] +@ CHECK: hintlt #15 @ encoding: [0xf0,0xbf] +@ CHECK: hintge.w #16 @ encoding: [0xaf,0xf3,0x10,0x80] +@ CHECK: hintlt.w #239 @ encoding: [0xaf,0xf3,0xef,0x80] + @------------------------------------------------------------------------------ @ Unallocated wide/narrow hints @------------------------------------------------------------------------------ diff --git a/test/MC/ARM/invalid-hint-arm.s b/test/MC/ARM/invalid-hint-arm.s new file mode 100644 index 0000000..49a2e5c --- /dev/null +++ b/test/MC/ARM/invalid-hint-arm.s @@ -0,0 +1,8 @@ +@ RUN: not llvm-mc -triple=armv7-apple-darwin -mcpu=cortex-a8 < %s 2>&1 | FileCheck %s + +hint #240 +hint #1000 + +@ CHECK: error: immediate operand must be in the range [0,239] +@ CHECK: error: immediate operand must be in the range [0,239] + diff --git a/test/MC/ARM/invalid-hint-thumb.s b/test/MC/ARM/invalid-hint-thumb.s new file mode 100644 index 0000000..d2b50c4 --- /dev/null +++ b/test/MC/ARM/invalid-hint-thumb.s @@ -0,0 +1,8 @@ +@ RUN: not llvm-mc -triple=thumbv7-apple-darwin -mcpu=cortex-a8 < %s 2>&1 | FileCheck %s + +hint #240 +hint #1000 + +@ CHECK: error: immediate operand must be in the range [0,239] +@ CHECK: error: immediate operand must be in the range [0,239] + diff --git a/test/MC/Disassembler/ARM/thumb2.txt b/test/MC/Disassembler/ARM/thumb2.txt index c8a24ee..c8b4080 100644 --- a/test/MC/Disassembler/ARM/thumb2.txt +++ b/test/MC/Disassembler/ARM/thumb2.txt @@ -2710,7 +2710,11 @@ #------------------------------------------------------------------------------ # Unallocated hints (They execute as NOPs, but software must not use them.) #------------------------------------------------------------------------------ - -[0x60 0xbf] # CHECK: hint #6 +# CHECK: hint.w #6 +# CHECK: hint.w #102 + +0x60 0xbf +0xaf 0xf3 0x06 0x80 +0xaf 0xf3 0x66 0x80 |