aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2012-05-28 14:20:19 +0000
committerNick Clifton <nickc@redhat.com>2012-05-28 14:20:19 +0000
commit7bfd842d05042bfa697b1ded0c8f9bf3e58171fe (patch)
treec85993ba7425bfecd4c4644402f98e36969b4306 /gas/testsuite
parente54e67a9e9744fbc370157d6ccd7f90859026ed3 (diff)
downloadgdb-7bfd842d05042bfa697b1ded0c8f9bf3e58171fe.zip
gdb-7bfd842d05042bfa697b1ded0c8f9bf3e58171fe.tar.gz
gdb-7bfd842d05042bfa697b1ded0c8f9bf3e58171fe.tar.bz2
* read.c (read_symbol_name): New function. Reads a symbol names.
Allows escape codes in names. (s_comm_internal): Use read_symbol_name. (s_globl, s_lsym, s_set, s_weakref): Likewise. * doc/as.texinfo: Document support for multibyte characters in symbol names. * gas/elf/syms.s: New test - checks the generation of multibyte symbol names. * gas/elf/syms.d: New file - expected readelf output. * gas/elf/elf.exp: Add syms. * readelf.c (print_symbol): Display multibyte characters in symbol names. (process_section_headers): Use print_symbol. * ld-ifunc/ifunc-13a-i386.s: Fix use of .global directive. * ld-ifunc/ifunc-15a-i385.s: Likewise.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/ChangeLog7
-rw-r--r--gas/testsuite/gas/elf/elf.exp2
-rw-r--r--gas/testsuite/gas/elf/syms.d18
-rw-r--r--gas/testsuite/gas/elf/syms.s5
4 files changed, 32 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 13a6344..e19086a 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2012-05-28 Nick Clifton <nickc@redhat.com>
+
+ * gas/elf/syms.s: New test - checks the generation of multibyte
+ symbol names.
+ * gas/elf/syms.d: New file - expected readelf output.
+ * gas/elf/elf.exp: Add syms.
+
2012-05-25 Alan Modra <amodra@gmail.com>
* gas/lns/lns-big-delta.s: Add nops.
diff --git a/gas/testsuite/gas/elf/elf.exp b/gas/testsuite/gas/elf/elf.exp
index 736eec9..b437730 100644
--- a/gas/testsuite/gas/elf/elf.exp
+++ b/gas/testsuite/gas/elf/elf.exp
@@ -184,6 +184,8 @@ if { [is_elf_format] } then {
run_dump_test "bad-size"
run_dump_test "bad-group"
+ run_dump_test "syms"
+
load_lib gas-dg.exp
dg-init
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/err-*.s $srcdir/$subdir/warn-*.s]] "" ""
diff --git a/gas/testsuite/gas/elf/syms.d b/gas/testsuite/gas/elf/syms.d
new file mode 100644
index 0000000..40f7706
--- /dev/null
+++ b/gas/testsuite/gas/elf/syms.d
@@ -0,0 +1,18 @@
+#readelf: -S -s -p .strtab
+#name: Multibyte symbol names
+# The following targets use an unusual .set syntax...
+#not-target: alpha*-*-* h8300-*-*
+
+#...
+Section Headers:
+#...
+ \[ .\] sec.*tion.*
+#...
+Symbol table.*
+#...
+ ..: .*sy.*mbol
+#...
+String dump.*
+#...
+ \[......\] sy.*mbol
+#pass
diff --git a/gas/testsuite/gas/elf/syms.s b/gas/testsuite/gas/elf/syms.s
new file mode 100644
index 0000000..977c6bb
--- /dev/null
+++ b/gas/testsuite/gas/elf/syms.s
@@ -0,0 +1,5 @@
+ .section "sec\xa5\xc2tion"
+
+ .set "sy\xa5\xc2mbol", .
+
+ .string8 "str\xa5\xc2ing"