aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2000-06-13 21:23:28 +0000
committerNick Clifton <nickc@redhat.com>2000-06-13 21:23:28 +0000
commitaa787a89597ec19c654f7edf7c6a7a33bef6ccc7 (patch)
tree53fef4a06fa200a45eff49a0dd7b27174cf4eb6d /gas
parent2104a50e3e7d2d543fa1ae5dc8393a985e1f786c (diff)
downloadgdb-aa787a89597ec19c654f7edf7c6a7a33bef6ccc7.zip
gdb-aa787a89597ec19c654f7edf7c6a7a33bef6ccc7.tar.gz
gdb-aa787a89597ec19c654f7edf7c6a7a33bef6ccc7.tar.bz2
Add test of macro expansion of string arguments.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog7
-rw-r--r--gas/testsuite/gas/arm/arm.exp2
-rw-r--r--gas/testsuite/gas/macros/macros.exp2
-rw-r--r--gas/testsuite/gas/macros/strings.d8
-rw-r--r--gas/testsuite/gas/macros/strings.s17
5 files changed, 35 insertions, 1 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 9f702bb..79c29b2 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2000-06-09 Nick Clifton <nickc@cygnus.com>
+
+ * gas/macros/macros.exp: Run new test: strings.
+ * gas/macros/strings.s: New test: String expansion inside
+ macros.
+ * gas/macros/strings.d: New test results.
+
2000-06-04 Alan Modra <alan@linuxcare.com.au>
* gas/i386/prefix.s: Modify so we have at least one x86 test that
diff --git a/gas/testsuite/gas/arm/arm.exp b/gas/testsuite/gas/arm/arm.exp
index f21c54d..d658eeb 100644
--- a/gas/testsuite/gas/arm/arm.exp
+++ b/gas/testsuite/gas/arm/arm.exp
@@ -1,7 +1,7 @@
#
# Some ARM tests
#
-if [istarget arm-*-*] then {
+if [istarget *arm*-*-*] then {
run_dump_test "inst"
gas_test "arm3.s" "" $stdoptlist "Arm 3 instructions"
diff --git a/gas/testsuite/gas/macros/macros.exp b/gas/testsuite/gas/macros/macros.exp
index a51e485..f75df40 100644
--- a/gas/testsuite/gas/macros/macros.exp
+++ b/gas/testsuite/gas/macros/macros.exp
@@ -20,3 +20,5 @@ case $target_triplet in {
run_dump_test semi
}
}
+
+run_dump_test strings
diff --git a/gas/testsuite/gas/macros/strings.d b/gas/testsuite/gas/macros/strings.d
new file mode 100644
index 0000000..546ff0f
--- /dev/null
+++ b/gas/testsuite/gas/macros/strings.d
@@ -0,0 +1,8 @@
+#objdump: -s -j .data
+#name: strings
+
+.*: .*
+
+Contents of section .data:
+ 0000 5c22666f 6f5c2200 62617200 62617a \\\"foo\\\".bar.baz
+
diff --git a/gas/testsuite/gas/macros/strings.s b/gas/testsuite/gas/macros/strings.s
new file mode 100644
index 0000000..88b2377
--- /dev/null
+++ b/gas/testsuite/gas/macros/strings.s
@@ -0,0 +1,17 @@
+.macro M arg1
+ .ascii "\arg1"
+.endm
+
+ .data
+foo:
+ M "\\\"foo\\\""
+
+ .balign 2
+
+ M "bar"
+
+ .balign 2
+
+ M baz
+
+