* ld-elfvsb/hidden2.d: Expect OBJECT.
authorDaniel Jacobowitz <drow@false.org>
Tue, 22 Feb 2005 18:29:20 +0000 (18:29 +0000)
committerDaniel Jacobowitz <drow@false.org>
Tue, 22 Feb 2005 18:29:20 +0000 (18:29 +0000)
* ld-elfvsb/hidden2.s: Force type OBJECT.
* ld-elfvsb/hidden2.ld: Place .dynamic explicitly.
* ld-elf/start.s: Provide __start for MIPS.
* ld-elfcomm/elfcomm.exp: Accept MIPS common section.  XFAIL size change
test.
* ld-elf/warn1.d: Use group.ld instead of -Ttext.

ld/testsuite/ChangeLog
ld/testsuite/ld-elf/start.s
ld/testsuite/ld-elf/warn1.d
ld/testsuite/ld-elfcomm/elfcomm.exp
ld/testsuite/ld-elfvsb/hidden2.d
ld/testsuite/ld-elfvsb/hidden2.ld
ld/testsuite/ld-elfvsb/hidden2.s

index 6b9f5fb..bebbb15 100644 (file)
@@ -1,3 +1,13 @@
+2005-02-22  Daniel Jacobowitz  <dan@codesourcery.com>
+
+       * ld-elfvsb/hidden2.d: Expect OBJECT.
+       * ld-elfvsb/hidden2.s: Force type OBJECT.
+       * ld-elfvsb/hidden2.ld: Place .dynamic explicitly.
+       * ld-elf/start.s: Provide __start for MIPS.
+       * ld-elfcomm/elfcomm.exp: Accept MIPS common section.  XFAIL size change
+       test.
+       * ld-elf/warn1.d: Use group.ld instead of -Ttext.
+
 2005-02-21  Alan Modra  <amodra@bigpond.net.au>
 
        * lib/ld-lib.exp (run_dump_test): Don't require a dump program if
index f4c8af6..86fc17c 100644 (file)
@@ -1,4 +1,6 @@
        .text
        .global _start
 _start:
+       .global __start
+__start:
        .long 0
index 80f32b9..d5ee7b4 100644 (file)
@@ -1,7 +1,7 @@
 #source: start.s
 #source: symbol1ref.s
 #source: symbol1w.s
-#ld: -Ttext 0x1000
+#ld: -T group.ld
 #warning: ^[^\\n]*\): warning: witty one-liner$
 #readelf: -s
 #notarget: "sparc64-*-solaris2*" "sparcv9-*-solaris2*"
index e5bd29b..e84377a 100644 (file)
@@ -45,7 +45,7 @@ proc dump_common1 { testname } {
 
     send_log "$READELF -s tmpdir/common1.o | grep foo\n"
     catch "exec $READELF -s tmpdir/common1.o | grep foo" exec_output
-    if { ![regexp "(\[         \]*)(\[0-9\]+):(\[      \]*)(\[0\]*)80(\[       \]+)4(\[        \]+)OBJECT(\[   \]+)GLOBAL(\[   \]+)DEFAULT(\[  \]+)COM(\[      \]+)_?foo2" $exec_output]
+    if { ![regexp "(\[         \]*)(\[0-9\]+):(\[      \]*)(\[0\]*)80(\[       \]+)4(\[        \]+)OBJECT(\[   \]+)GLOBAL(\[   \]+)DEFAULT(\[  \]+)(PRC\\\[0xff03\\\]|COM)(\[  \]+)_?foo2" $exec_output]
         || ![regexp "(\[       \]*)(\[0-9\]+):(\[      \]*)(\[0-9\]+)(\[       \]+)21(\[       \]+)OBJECT(\[   \]+)GLOBAL(\[   \]+)DEFAULT(\[  \]+)(\[0-9\]+)(\[       \]+)_?foo1" $exec_output] } {
        send_log "$exec_output\n"
        verbose $exec_output
@@ -72,7 +72,13 @@ if { [ld_simple_link $ld tmpdir/common1.o "-r tmpdir/common1a.o tmpdir/common1b.
 
 if { ![regexp "Warning: alignment (\[0-9\]+) of symbol \`_?foo1\' in tmpdir/common1b.o is smaller than 64 in tmpdir/common1a.o" $link_output]
      || ![regexp "Warning: size of symbol \`_?foo1\' changed from 2 in tmpdir/common1a.o to 21 in tmpdir/common1b.o" $link_output] } {
-    fail $test1w1
+    if { [istarget mips*-*-*] } {
+       # This test fails on MIPS because the backend sets type_change_ok.  The
+       # size change warning is suppressed.
+       xfail $test1w1
+    } else {
+       fail $test1w1
+    }
 } else {
     pass $test1w1
 }
index 25cfa4d..14b0b30 100644 (file)
@@ -5,5 +5,5 @@
 
 Symbol table for image:
 #...
-[      ]*[0-9]+ +[0-9]+: [0-9a-fA-F]* +0  NOTYPE  LOCAL HIDDEN +ABS foo
+[      ]*[0-9]+ +[0-9]+: [0-9a-fA-F]* +0  OBJECT  LOCAL HIDDEN +ABS foo
 #pass
index 1e4a2b0..3c414db 100644 (file)
@@ -3,4 +3,5 @@ SECTIONS
   . = 0x1000;
   PROVIDE (foo = .);
   .data : { *(.data) }
+  .dynamic : { *(.dynamic) }
 }
index beb123b..62f1107 100644 (file)
@@ -1,4 +1,5 @@
        .data
        .hidden foo
        .global foo
+       .type foo,%object
        .dc.a foo