ld: Fix failures in new orphan handling tests.
authorAndrew Burgess <andrew.burgess@embecosm.com>
Mon, 7 Sep 2015 14:39:12 +0000 (15:39 +0100)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Mon, 7 Sep 2015 22:28:04 +0000 (23:28 +0100)
The new orphan handling tests added in commit c005eb9 fail on a range of
targets.  Some of the failures were fixed in commit e32aa93 but not
all.  This commit should address the remaining failures.

Update results to account for orphan sections being placed in different
orders, and for other, target specific sections, being discarded.

ld/testsuite/ChangeLog:

* ld-elf/orphan-7.map: Allow for other discarded sections.
* ld-elf/orphan-8.map: Updated to allow for different section
ordering on different targets.
* ld-elf/orphan.ld: Place .sbss section.

ld/testsuite/ChangeLog
ld/testsuite/ld-elf/orphan-7.map
ld/testsuite/ld-elf/orphan-8.map
ld/testsuite/ld-elf/orphan.ld

index 6ca3083d22d3aed2a16074a9282ae5210c40eff8..c92d1e4538b4845ff49e2be41771f5b2fea97747 100644 (file)
@@ -1,3 +1,10 @@
+2015-09-07  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+       * ld-elf/orphan-7.map: Allow for other discarded sections.
+       * ld-elf/orphan-8.map: Updated to allow for different section
+       ordering on different targets.
+       * ld-elf/orphan.ld: Place .sbss section.
+
 2015-09-05  H.J. Lu  <hongjiu.lu@intel.com>
 
        * ld-elf/orphan-8.map: Updated to support 32-bit targets.
index 52cc359d34a2aced5b874a6d2a2e2103c868576d..888cb8065191a5dbc09831c76f72a00dd3eccac7 100644 (file)
@@ -1,7 +1,8 @@
-
+#...
 Discarded input sections
-
+#...
  \.notbad        0x0+        0x4 tmpdir/.*\.o
  \.note\.bar      0x0+        0x4 tmpdir/.*\.o
-
 #...
+Linker script and memory map
+#...
\ No newline at end of file
index 0bd97666b8b7486aa6c9878d2adc2c1375f54340..308d4277c20c4ee71339a8923d32c36ce77984f2 100644 (file)
@@ -1,7 +1,7 @@
 #...
-.notbad         0x0+4        0x4
- .notbad        0x0+4        0x4 tmpdir/dump0.o
+.notbad         0x[0-9a-f]+        0x4
+ .notbad        0x[0-9a-f]+        0x4 tmpdir/dump0.o
 #...
-.note.bar       0x0+10        0x4
- .note.bar      0x0+10        0x4 tmpdir/dump0.o
+.note.bar       0x[0-9a-f]+        0x4
+ .note.bar      0x[0-9a-f]+        0x4 tmpdir/dump0.o
 #...
index 44eb7eb254e89bb835b2c499581dee095027ec18..1ae908b126816604cc85a37f60199b747ecc0d5a 100644 (file)
@@ -3,6 +3,7 @@ SECTIONS
   .text : { *(.text) }
   .data : { *(.data) }
   .bss : { *(.bss) *(COMMON) }
+  .sbss : { *(.sbss) }
   .note : { *(.note) }
   /DISCARD/ : { *(.reginfo) *(.MIPS.abiflags) *(.trampolines) }
 }