This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] MIPS TESTSUITE LD: Skip o32 flags check on mips*-*-irix*


Hi:

The following test fails on mips-sgi-irix6.

FAIL: MIPS compatible objects:  "-mips4 -mgp32 -32"  "-mips2 -32"
FAIL: MIPS compatible objects:  "-mips4 -mabi=32"    "-mips2 -32"
FAIL: MIPS compatible objects:  "-mips2 -32"         "-mips4 -mabi=32"
FAIL: MIPS compatible objects:  "-march=vr4120 -mabi=32"  "-mips3 -mabi=32"
FAIL: MIPS compatible objects:  "-march=sb1 -mgp32 -32"   "-march=4000
-mgp32 -32"
FAIL: MIPS compatible objects:  "-mips32 -mabi=32"        "-march=sb1 -mabi=32"
FAIL: MIPS compatible objects:  "-mips64r2 -mabi=32"      "-mips32 -mabi=32"

The mips*-*-irix* do not understand o32 flags according to
gas/configure.ac:325~332

325         # See whether it's appropriate to set E_MIPS_ABI_O32 for o32
326         # binaries.  It's a GNU extension that some OSes don't understand.
327         case ${target} in
328           *-*-irix*)
329             use_e_mips_abi_o32=0
330             ;;
331           *)
332             use_e_mips_abi_o32=1

The attached patch skips o32 flags checking if the target is mips*-*-irix*.

ld/ChangeLog
2018-08-25  Chenghua Xu  <paul.hua.gm@gmail.com>

        * testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
        Skip o32 flags checking if target is mips*-*-irix*.
diff --git a/ld/testsuite/ld-mips-elf/mips-elf-flags.exp b/ld/testsuite/ld-mips-elf/mips-elf-flags.exp
index de97939..0a4bdf1 100644
--- a/ld/testsuite/ld-mips-elf/mips-elf-flags.exp
+++ b/ld/testsuite/ld-mips-elf/mips-elf-flags.exp
@@ -127,7 +127,12 @@ proc good_combination {arglist flags args} {
 
 	    foreach flag $flags {
 		if {[lsearch -exact $gotflags $flag] < 0} {
-		    set failed 1
+		    # The mips*-*-irix* not use o32 flags.
+		    if {[istarget mips*-*-irix*] && $flag == "o32"} {
+			set failed 0
+		    } else {
+			set failed 1
+		    }
 		}
 	    }
 

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]