aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>1999-06-05 23:14:42 +0000
committerRichard Henderson <rth@redhat.com>1999-06-05 23:14:42 +0000
commit9894490542aa133d03f55b98fe59fabbfde335c0 (patch)
tree3b4e1e53a41d57db686c155f3efbf0a35d0232cd /gas
parent58b5739a4e998799ab1b3bf8bb7720d176f50b72 (diff)
downloadgdb-9894490542aa133d03f55b98fe59fabbfde335c0.zip
gdb-9894490542aa133d03f55b98fe59fabbfde335c0.tar.gz
gdb-9894490542aa133d03f55b98fe59fabbfde335c0.tar.bz2
* gas/elf/elf.exp: New directory.
* gas/elf/section0.[sd]: New test. * gas/elf/section1.[sd]: New test.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog6
-rw-r--r--gas/testsuite/gas/elf/elf.exp14
-rw-r--r--gas/testsuite/gas/elf/section0.d14
-rw-r--r--gas/testsuite/gas/elf/section0.s16
-rw-r--r--gas/testsuite/gas/elf/section1.d14
-rw-r--r--gas/testsuite/gas/elf/section1.s32
6 files changed, 96 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 67b7a7f..f85f239 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+1999-06-05 Richard Henderson <rth@cygnus.com>
+
+ * gas/elf/elf.exp: New directory.
+ * gas/elf/section0.[sd]: New test.
+ * gas/elf/section1.[sd]: New test.
+
1999-06-03 Philip Blundell <philb@gnu.org>
* gas/arm/arm7t.d, gas/arm/inst.d: Update to match current gas,
diff --git a/gas/testsuite/gas/elf/elf.exp b/gas/testsuite/gas/elf/elf.exp
new file mode 100644
index 0000000..274b9ce
--- /dev/null
+++ b/gas/testsuite/gas/elf/elf.exp
@@ -0,0 +1,14 @@
+#
+# elf tests
+#
+
+# We're testing bits in obj-elf -- don't run on anything else.
+if { [istarget "*-elf*"]
+ || [istarget "*-linux*"]
+ || [istarget "sparc*-*-solaris*"]
+ || [istarget "mips*-*-irix6*"] } then {
+
+ run_dump_test "section0"
+ run_dump_test "section1"
+
+}
diff --git a/gas/testsuite/gas/elf/section0.d b/gas/testsuite/gas/elf/section0.d
new file mode 100644
index 0000000..60547c2
--- /dev/null
+++ b/gas/testsuite/gas/elf/section0.d
@@ -0,0 +1,14 @@
+#objdump: -s
+#name: elf section0
+
+.*: +file format .*
+
+Contents of section .text:
+Contents of section .data:
+ 0000 0000 ..
+Contents of section A:
+ 0000 010101 ...
+Contents of section B:
+ 0000 0202 ..
+Contents of section C:
+ 0000 03 .
diff --git a/gas/testsuite/gas/elf/section0.s b/gas/testsuite/gas/elf/section0.s
new file mode 100644
index 0000000..bdc8f0c
--- /dev/null
+++ b/gas/testsuite/gas/elf/section0.s
@@ -0,0 +1,16 @@
+.data
+ .byte 0
+.section A
+ .byte 1
+.pushsection B
+ .byte 2
+.pushsection C
+ .byte 3
+.popsection
+ .byte 2
+.popsection
+ .byte 1
+.previous
+ .byte 0
+.previous
+ .byte 1
diff --git a/gas/testsuite/gas/elf/section1.d b/gas/testsuite/gas/elf/section1.d
new file mode 100644
index 0000000..52a16a3
--- /dev/null
+++ b/gas/testsuite/gas/elf/section1.d
@@ -0,0 +1,14 @@
+#objdump: -s
+#name: elf section1
+
+.*: +file format .*
+
+Contents of section .text:
+Contents of section .data:
+ 0000 000000 ...
+Contents of section A:
+ 0000 01010101 0101 ......
+Contents of section B:
+ 0000 02020202 02 .....
+Contents of section C:
+ 0000 0303 ..
diff --git a/gas/testsuite/gas/elf/section1.s b/gas/testsuite/gas/elf/section1.s
new file mode 100644
index 0000000..1592adf
--- /dev/null
+++ b/gas/testsuite/gas/elf/section1.s
@@ -0,0 +1,32 @@
+.data
+ .byte 0
+.section A
+ .byte 1
+.previous
+ .byte 0
+.previous
+ .byte 1
+.pushsection B
+ .byte 2
+.previous
+ .byte 1
+.previous
+ .byte 2
+.pushsection C
+ .byte 3
+.previous
+ .byte 2
+.previous
+ .byte 3
+.popsection
+ .byte 2
+.previous
+ .byte 1
+.previous
+ .byte 2
+.popsection
+ .byte 1
+.previous
+ .byte 0
+.previous
+ .byte 1