summaryrefslogtreecommitdiffstats
path: root/llvm/test/MC/ARM/inst-overflow.s
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2013-12-19 05:17:58 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2013-12-19 05:17:58 +0000
commitc0da2cb3b4951531d6d6aa49367c1554d007d410 (patch)
tree3a2cdb7670d1150b3f55987c0ea85ae3f86688fe /llvm/test/MC/ARM/inst-overflow.s
parent91e428bc90e1ef1cf6efda7bb3c4074501c2dfa3 (diff)
downloadbcm5719-llvm-c0da2cb3b4951531d6d6aa49367c1554d007d410.tar.gz
bcm5719-llvm-c0da2cb3b4951531d6d6aa49367c1554d007d410.zip
ARM IAS: support .inst directive
This adds support for the .inst directive. This is an ARM specific directive to indicate an instruction encoded as a constant expression. The major difference between .word, .short, or .byte and .inst is that the latter will be disassembled as an instruction since it does not get flagged as data. llvm-svn: 197657
Diffstat (limited to 'llvm/test/MC/ARM/inst-overflow.s')
-rw-r--r--llvm/test/MC/ARM/inst-overflow.s14
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/test/MC/ARM/inst-overflow.s b/llvm/test/MC/ARM/inst-overflow.s
new file mode 100644
index 00000000000..133d53f7430
--- /dev/null
+++ b/llvm/test/MC/ARM/inst-overflow.s
@@ -0,0 +1,14 @@
+@ RUN: not llvm-mc %s -triple armv7-linux-gnueabi -filetype asm -o - 2>&1 \
+@ RUN: | FileCheck -check-prefix CHECK-ERROR %s
+
+ .syntax unified
+ .arm
+
+ .align 2
+ .global constant_overflow
+ .type constant_overflow,%function
+constant_overflow:
+ .inst 1 << 32
+@ CHECK-ERROR: inst operand is too big
+
+
OpenPOWER on IntegriCloud