aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorMatthew Gretton-Dann <matthew.gretton-dann@arm.com>2010-09-27 09:47:05 +0000
committerMatthew Gretton-Dann <matthew.gretton-dann@arm.com>2010-09-27 09:47:05 +0000
commit6844b2c2db8ce07c7f000d9bd132d6b9b83709b8 (patch)
tree5fcdbc72bb96397a0323bdda04fd5533d4a96d05 /gas/testsuite
parenta7cb5251cf141989cc34f39b40641c5359b12757 (diff)
downloadgdb-6844b2c2db8ce07c7f000d9bd132d6b9b83709b8.zip
gdb-6844b2c2db8ce07c7f000d9bd132d6b9b83709b8.tar.gz
gdb-6844b2c2db8ce07c7f000d9bd132d6b9b83709b8.tar.bz2
2010-09-27 Tejas Belagod <tejas.belagod@arm.com>
* gas/config/tc-arm.c (do_neon_ldr_str): Deprecate ARM-mode PC-relative VSTR, issue an error in THUMB mode. * opcodes/arm_dis.c (print_insn_coprocessor): Apply off-by-alignment correction to unaligned PCs while printing comment. * gas/testsuite/gas/arm/vldr.s: New test for pc-relative VLDR disassembly comment. * gas/testsuite/gas/arm/vldr.d: Likewise. * gas/testsuite/gas/arm/vstr-bad.s: New test for PC-relative VSTR. * gas/testsuite/gas/arm/vstr-thumb-bad.l: Likewise. * gas/testsuite/gas/arm/vstr-thumb-bad.d: Likewise. * gas/testsuite/gas/arm/vstr-arm-bad.l: Likewise. * gas/testsuite/gas/arm/vstr-arm-bad.d: Likewise.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/ChangeLog10
-rw-r--r--gas/testsuite/gas/arm/vldr.d15
-rw-r--r--gas/testsuite/gas/arm/vldr.s10
-rw-r--r--gas/testsuite/gas/arm/vstr-arm-bad.d4
-rw-r--r--gas/testsuite/gas/arm/vstr-arm-bad.l3
-rw-r--r--gas/testsuite/gas/arm/vstr-bad.s12
-rw-r--r--gas/testsuite/gas/arm/vstr-thumb-bad.d4
-rw-r--r--gas/testsuite/gas/arm/vstr-thumb-bad.l3
8 files changed, 61 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 038c561..14524c6 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,13 @@
+2010-09-27 Tejas Belagod <tejas.belagod@arm.com>
+
+ * gas/arm/vldr.s: New test for pc-relative VLDR disassembly comment.
+ * gas/arm/vldr.d: Likewise.
+ * gas/arm/vstr-bad.s: New test for PC-relative VSTR.
+ * gas/arm/vstr-thumb-bad.l: Likewise.
+ * gas/arm/vstr-thumb-bad.d: Likewise.
+ * gas/arm/vstr-arm-bad.l: Likewise.
+ * gas/arm/vstr-arm-bad.d: Likewise.
+
2010-09-23 Matthew Gretton-Dann <matthew.gretton-dann@arm.com>
* gas/arm/armv7-a+virt.d: New test.
diff --git a/gas/testsuite/gas/arm/vldr.d b/gas/testsuite/gas/arm/vldr.d
new file mode 100644
index 0000000..d5c9331
--- /dev/null
+++ b/gas/testsuite/gas/arm/vldr.d
@@ -0,0 +1,15 @@
+# name: VFP VLDR
+# as: -mfpu=vfp3 -mcpu=cortex-a8 -mthumb
+# source: vldr.s
+# objdump: -dr --prefix-addresses --show-raw-insn
+
+.*: +file format .*arm.*
+
+Disassembly of section .text:
+0[0-9a-f]+ <[^>]+> bf00 nop
+0[0-9a-f]+ <[^>]+> ed9f 0b03 vldr d0, \[pc, #12\] ; 00000010 <float>
+0[0-9a-f]+ <[^>]+> ed9f 0b02 vldr d0, \[pc, #8\] ; 00000010 <float>
+0[0-9a-f]+ <[^>]+> bf00 nop
+0[0-9a-f]+ <[^>]+> bf00 nop
+0[0-9a-f]+ <[^>]+> bf00 nop
+ ...
diff --git a/gas/testsuite/gas/arm/vldr.s b/gas/testsuite/gas/arm/vldr.s
new file mode 100644
index 0000000..86bc82e
--- /dev/null
+++ b/gas/testsuite/gas/arm/vldr.s
@@ -0,0 +1,10 @@
+.syntax unified
+.text
+ nop
+ vldr d0, float
+ vldr d0, float
+ nop
+ nop
+
+.align
+float: .double 0.0
diff --git a/gas/testsuite/gas/arm/vstr-arm-bad.d b/gas/testsuite/gas/arm/vstr-arm-bad.d
new file mode 100644
index 0000000..32a041f
--- /dev/null
+++ b/gas/testsuite/gas/arm/vstr-arm-bad.d
@@ -0,0 +1,4 @@
+# name: VFP PC-relative VSTR arm mode
+# as: -mfpu=vfp3 -mcpu=cortex-a8
+# source: vstr-bad.s
+# error-output: vstr-arm-bad.l
diff --git a/gas/testsuite/gas/arm/vstr-arm-bad.l b/gas/testsuite/gas/arm/vstr-arm-bad.l
new file mode 100644
index 0000000..0d48327
--- /dev/null
+++ b/gas/testsuite/gas/arm/vstr-arm-bad.l
@@ -0,0 +1,3 @@
+[^:]*: Assembler messages:
+[^:]*:6: Warning: Use of PC here is deprecated
+[^:]*:7: Warning: Use of PC here is deprecated
diff --git a/gas/testsuite/gas/arm/vstr-bad.s b/gas/testsuite/gas/arm/vstr-bad.s
new file mode 100644
index 0000000..f5a1365
--- /dev/null
+++ b/gas/testsuite/gas/arm/vstr-bad.s
@@ -0,0 +1,12 @@
+
+.syntax unified
+.text
+
+ nop
+ vstr d0, float
+ vstr d0, [pc, #4]
+ nop
+ nop
+
+.align
+float: .double 0.0
diff --git a/gas/testsuite/gas/arm/vstr-thumb-bad.d b/gas/testsuite/gas/arm/vstr-thumb-bad.d
new file mode 100644
index 0000000..798f16d
--- /dev/null
+++ b/gas/testsuite/gas/arm/vstr-thumb-bad.d
@@ -0,0 +1,4 @@
+# name: VFP PC-relative VSTR thumb mode
+# as: -mfpu=vfp3 -mthumb -mcpu=cortex-a8
+# source: vstr-bad.s
+# error-output: vstr-thumb-bad.l
diff --git a/gas/testsuite/gas/arm/vstr-thumb-bad.l b/gas/testsuite/gas/arm/vstr-thumb-bad.l
new file mode 100644
index 0000000..1660fbf
--- /dev/null
+++ b/gas/testsuite/gas/arm/vstr-thumb-bad.l
@@ -0,0 +1,3 @@
+[^:]*: Assembler messages:
+[^:]*:6: Error: Use of PC here is UNPREDICTABLE -- `vstr d0,float'
+[^:]*:7: Error: Use of PC here is UNPREDICTABLE -- `vstr d0,\[pc,#4\]'