Blame SOURCES/gdb-rhbz1125820-ppc64le-enablement-25of37.patch

2c2fa1
commit 6ed14ff33979bc48367c35b1b235fef8c5e2229b
2c2fa1
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
2c2fa1
Date:   Tue Feb 4 18:28:24 2014 +0100
2c2fa1
2c2fa1
    PowerPC64 little-endian fixes: AltiVec tests
2c2fa1
    
2c2fa1
    A couple of AltiVec tests fail spuriously on powerpc64le-linux, because
2c2fa1
    they compare against an incorrect pattern.  Note that those tests already
2c2fa1
    contain little-endian variants of the patterns, but those seem to have
2c2fa1
    bit-rotted a bit: when outputting a vector, GDB no longer omits trailing
2c2fa1
    zero elements (as it used to do in the past).
2c2fa1
    
2c2fa1
    This patch updates the pattern to the new GDB output behavior.
2c2fa1
    
2c2fa1
    In addition, the patch updates the endian test to use the new
2c2fa1
    gdb_test_multiple logic instead of gdb_expect.
2c2fa1
    
2c2fa1
    gdb/testsuite/ChangeLog:
2c2fa1
    
2c2fa1
    	* gdb.arch/altivec-regs.exp: Use gdb_test_multiple for endian test.
2c2fa1
    	(decimal_vector): Fix for little-endian.
2c2fa1
2c2fa1
Index: gdb-7.6.1/gdb/testsuite/gdb.arch/altivec-regs.exp
2c2fa1
===================================================================
2c2fa1
--- gdb-7.6.1.orig/gdb/testsuite/gdb.arch/altivec-regs.exp
2c2fa1
+++ gdb-7.6.1/gdb/testsuite/gdb.arch/altivec-regs.exp
2c2fa1
@@ -79,17 +79,16 @@ gdb_test "set \$vrsave = 1" "" ""
2c2fa1
 
2c2fa1
 gdb_test "next" "" ""
2c2fa1
 
2c2fa1
-send_gdb "show endian\n"
2c2fa1
 set endianness ""
2c2fa1
-gdb_expect {
2c2fa1
+set msg "detect endianness"
2c2fa1
+gdb_test_multiple "show endian" "$msg" {
2c2fa1
     -re "(The target endianness is set automatically .currently )(big|little)( endian.*)$gdb_prompt $" {
2c2fa1
-        pass "endianness"
2c2fa1
-	set endianness $expect_out(2,string)
2c2fa1
+        pass "$msg"
2c2fa1
+        set endianness $expect_out(2,string)
2c2fa1
     }
2c2fa1
     -re ".*$gdb_prompt $" {
2c2fa1
-	fail "couldn't get endianness"
2c2fa1
+        fail "$msg"
2c2fa1
     }
2c2fa1
-    timeout		{ fail "(timeout) endianness" }
2c2fa1
 }
2c2fa1
 
2c2fa1
 # And then read the AltiVec registers back, to see that
2c2fa1
@@ -118,7 +117,7 @@ gdb_test "info reg vscr" "vscr.*0x1\t1"
2c2fa1
 if {$endianness == "big"} {
2c2fa1
      set decimal_vector ".uint128 = 0x00000001000000010000000100000001, v4_float = .1.*e-45, 1.*e-45, 1.*e-45, 1.*e-45., v4_int32 = .1, 1, 1, 1., v8_int16 = .0, 1, 0, 1, 0, 1, 0, 1., v16_int8 = .0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1.."
2c2fa1
 } else {
2c2fa1
-     set decimal_vector ".uint128 = 0x00000001000000010000000100000001, v4_float = .1.*e-45, 1.*e-45, 1.*e-45, 1.*e-45., v4_int32 = .1, 1, 1, 1., v8_int16 = .1, 0, 1, 0, 1, 0, 1, 0., v16_int8 = .1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.."
2c2fa1
+     set decimal_vector ".uint128 = 0x00000001000000010000000100000001, v4_float = .1.*e-45, 1.*e-45, 1.*e-45, 1.*e-45., v4_int32 = .1, 1, 1, 1., v8_int16 = .1, 0, 1, 0, 1, 0, 1, 0., v16_int8 = .1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0.."
2c2fa1
 }
2c2fa1
 
2c2fa1
 for {set i 0} {$i < 32} {incr i 1} {