aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorArnold Metselaar <arnold.metselaar@planet.nl>2009-10-25 16:18:04 +0000
committerArnold Metselaar <arnold.metselaar@planet.nl>2009-10-25 16:18:04 +0000
commita39571ad49620595c2e9baf5b477c78eb7a22982 (patch)
treea397a8cc2fb4d0e9a4585b969c0d9a75401b1474 /gas
parent3c45a255a86c02939babfaf270721cffa9189b26 (diff)
downloadgdb-a39571ad49620595c2e9baf5b477c78eb7a22982.zip
gdb-a39571ad49620595c2e9baf5b477c78eb7a22982.tar.gz
gdb-a39571ad49620595c2e9baf5b477c78eb7a22982.tar.bz2
* gas/z80/equ.d, gas/z80/equ.s: Added test of parsing equ directives.
* gas/z80/z80.exp: Run it. * gas/z80/redef.d: Expect little endian output only.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog7
-rw-r--r--gas/testsuite/gas/z80/equ.d8
-rw-r--r--gas/testsuite/gas/z80/equ.s10
-rw-r--r--gas/testsuite/gas/z80/redef.d2
-rw-r--r--gas/testsuite/gas/z80/z80.exp2
5 files changed, 28 insertions, 1 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index b363b7a..e0008a2 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2009-10-25 Arnold Metselaar <arnold.metselaar@planet.nl>
+
+ * gas/z80/equ.d, gas/z80/equ.s: Added test of parsing equ directives.
+ * gas/z80/z80.exp: Run it.
+
+ * gas/z80/redef.d: Expect little endian output only.
+
2009-10-20 H.J. Lu <hongjiu.lu@intel.com>
PR gas/10775
diff --git a/gas/testsuite/gas/z80/equ.d b/gas/testsuite/gas/z80/equ.d
new file mode 100644
index 0000000..cba8db5
--- /dev/null
+++ b/gas/testsuite/gas/z80/equ.d
@@ -0,0 +1,8 @@
+#objdump: -s -j .data
+#name: .equ definitions
+
+.*: .*
+
+Contents of section .data:
+ 0000 0c000000 08000000 04000000 00000000[ ]+................[ ]*
+#pass
diff --git a/gas/testsuite/gas/z80/equ.s b/gas/testsuite/gas/z80/equ.s
new file mode 100644
index 0000000..11e828b
--- /dev/null
+++ b/gas/testsuite/gas/z80/equ.s
@@ -0,0 +1,10 @@
+ .data
+_start:
+lab0: .equ .-_start
+ .long lab3
+lab1: equ -(_start - .)
+ .long lab2
+lab2 .equ (.-_start)
+ .long lab1
+lab3 equ ~~(.-_start)
+ .long lab0
diff --git a/gas/testsuite/gas/z80/redef.d b/gas/testsuite/gas/z80/redef.d
index fed1998..aa982a4 100644
--- a/gas/testsuite/gas/z80/redef.d
+++ b/gas/testsuite/gas/z80/redef.d
@@ -4,5 +4,5 @@
.*: .*
Contents of section .data:
- 0000 00000000 0[04]00000[04] 0[08]00000[08] 0[0c]00000[0c][ ]+................[ ]*
+ 0000 00000000 04000000 08000000 0c000000[ ]+................[ ]*
#pass
diff --git a/gas/testsuite/gas/z80/z80.exp b/gas/testsuite/gas/z80/z80.exp
index d595f6a..0cb8440 100644
--- a/gas/testsuite/gas/z80/z80.exp
+++ b/gas/testsuite/gas/z80/z80.exp
@@ -3,6 +3,8 @@
if [istarget z80-*-*] then {
# test redefinitions
run_dump_test "redef"
+# test parsing of equ definitions
+ run_dump_test "equ"
# test parsing of " and '
run_dump_test "quotes"
# test suffixes