aboutsummaryrefslogtreecommitdiffstats
path: root/test/MC
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2013-10-24 12:22:58 +0000
committerTim Northover <tnorthover@apple.com>2013-10-24 12:22:58 +0000
commiteac623a18b1e7ad9e5a7da76a323039450b7d7ce (patch)
treeabac52072a6d7a34864c6275b658ad433f7350c7 /test/MC
parentef713e27b1b9f685adc1ae35526d92c6ad0324e5 (diff)
downloadexternal_llvm-eac623a18b1e7ad9e5a7da76a323039450b7d7ce.zip
external_llvm-eac623a18b1e7ad9e5a7da76a323039450b7d7ce.tar.gz
external_llvm-eac623a18b1e7ad9e5a7da76a323039450b7d7ce.tar.bz2
ARM: mark various aliases with their architecture requirements.
If an alias inherits directly from InstAlias then it doesn't get any default "Requires" values, so llvm-mc will allow it even on architectures that don't support the underlying instruction. This tidies up the obvious VFP and NEON cases I found. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193340 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/MC')
-rw-r--r--test/MC/ARM/diagnostics-noneon.s7
-rw-r--r--test/MC/ARM/diagnostics.s17
2 files changed, 24 insertions, 0 deletions
diff --git a/test/MC/ARM/diagnostics-noneon.s b/test/MC/ARM/diagnostics-noneon.s
new file mode 100644
index 0000000..310344a
--- /dev/null
+++ b/test/MC/ARM/diagnostics-noneon.s
@@ -0,0 +1,7 @@
+@ RUN: not llvm-mc -triple=armv7-apple-darwin -mattr=-neon < %s 2> %t
+@ RUN: FileCheck --check-prefix=CHECK-ERRORS < %t %s
+
+ vmov d5, d10
+ vmov q4, q5
+@ CHECK-ERRORS: error: instruction requires: NEON
+@ CHECK-ERRORS: error: instruction requires: NEON
diff --git a/test/MC/ARM/diagnostics.s b/test/MC/ARM/diagnostics.s
index 4942ba0..35069c7 100644
--- a/test/MC/ARM/diagnostics.s
+++ b/test/MC/ARM/diagnostics.s
@@ -438,3 +438,20 @@
@ CHECK-ERRORS: error: writeback register not allowed in register list
@ CHECK-ERRORS: error: writeback register not allowed in register list
@ CHECK-ERRORS: error: writeback register not allowed in register list
+
+ vrintz.f32.f32 s0, s1
+ vrintr.f32 s0, s1
+ vrintx.f64.f64 d2, d5
+ vrintz.f64 d10, d9
+ vrinta.f32.f32 s6, s7
+ vrintn.f32 s8, s9
+ vrintp.f64.f64 d10, d11
+ vrintm.f64 d12, d13
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8
+@ CHECK-ERRORS: error: instruction requires: FPARMv8