aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2014-12-26 18:26:38 +1030
committerAlan Modra <amodra@gmail.com>2014-12-26 22:19:30 +1030
commit0abb10c82d2c202e34b87104d51080b6d1de26d1 (patch)
tree4f211507a1f305f051730309e436c23f7f976006 /binutils
parentff600205664cc39be32910e4bf36c3de8183f93c (diff)
downloadgdb-0abb10c82d2c202e34b87104d51080b6d1de26d1.zip
gdb-0abb10c82d2c202e34b87104d51080b6d1de26d1.tar.gz
gdb-0abb10c82d2c202e34b87104d51080b6d1de26d1.tar.bz2
Delete unnecessary code copying SHF_SH5_ISA32 flag
Since 2006, commit d270463e9, _bfd_elf_copy_private_section_data has copied over SHF_MASKOS and SHF_MASKPROC flags. That makes the buggy code in sh_elf64_copy_private_data_internal redundant. bfd/ PR 17755 * elf64-sh64.c (sh_elf64_copy_private_data_internal): Delete code copying SHF_SH5_ISA32. binutils/testsuite/ * binutils-all/strip-11.d: New test. * binutils-all/objcopy.exp: Run it.
Diffstat (limited to 'binutils')
-rw-r--r--binutils/testsuite/ChangeLog5
-rw-r--r--binutils/testsuite/binutils-all/objcopy.exp6
-rw-r--r--binutils/testsuite/binutils-all/strip-11.d12
3 files changed, 23 insertions, 0 deletions
diff --git a/binutils/testsuite/ChangeLog b/binutils/testsuite/ChangeLog
index 8576710..81d89c4 100644
--- a/binutils/testsuite/ChangeLog
+++ b/binutils/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2014-12-26 Alan Modra <amodra@gmail.com>
+
+ * binutils-all/strip-11.d: New test.
+ * binutils-all/objcopy.exp: Run it.
+
2014-12-06 Eric Botcazou <ebotcazou@adacore.com>
* binutils-all/objcopy.exp: Skip strip-10 for Visium.
diff --git a/binutils/testsuite/binutils-all/objcopy.exp b/binutils/testsuite/binutils-all/objcopy.exp
index c83825a..e7b792e 100644
--- a/binutils/testsuite/binutils-all/objcopy.exp
+++ b/binutils/testsuite/binutils-all/objcopy.exp
@@ -960,6 +960,12 @@ if [is_elf_format] {
&& !([istarget "arm*-*-*"] && ![istarget "arm-*-*eabi*"])} {
run_dump_test "strip-10"
}
+ set extra_strip11 ""
+ if { [istarget "sh64*-*"] } {
+ # pr17755 testcase
+ set extra_strip11 { { "as" "--isa=SHmedia --abi=64" } }
+ }
+ run_dump_test "strip-11" $extra_strip11
if { [istarget "i*86-*"] || [istarget "x86_64-*-*"] } {
# Check to make sure we don't strip a symbol named in relocations.
diff --git a/binutils/testsuite/binutils-all/strip-11.d b/binutils/testsuite/binutils-all/strip-11.d
new file mode 100644
index 0000000..04c47ab
--- /dev/null
+++ b/binutils/testsuite/binutils-all/strip-11.d
@@ -0,0 +1,12 @@
+#PROG: strip
+#source: empty.s
+#strip: -g
+#readelf: -S --wide
+#name: strip -g empty file
+
+#...
+ \[ 0\] +NULL +0+ .*
+#...
+ \[ .\] \.shstrtab +STRTAB +0+ .*
+Key to Flags:
+#pass