This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: Check is_amd64_regs_target to to set nr_regs


Hi,

We should check is_amd64_regs_target instead of is_ilp32_target to set
nr_regs.  X32 is a amd64_regs target as well as ilp32 target.  OK to
install?

Thanks.

H.J.
---
2012-10-11  H.J. Lu  <hongjiu.lu@intel.com>

	* gdb.arch/i386-avx.exp: Check is_amd64_regs_target instead of
	is_ilp32_target to set nr_regs.
	* gdb.arch/i386-sse.exp: Likewise.

diff --git a/gdb/testsuite/gdb.arch/i386-avx.exp b/gdb/testsuite/gdb.arch/i386-avx.exp
index 52a6e4a..32ba5b6 100644
--- a/gdb/testsuite/gdb.arch/i386-avx.exp
+++ b/gdb/testsuite/gdb.arch/i386-avx.exp
@@ -73,10 +73,10 @@ gdb_test "break [gdb_get_line_number "first breakpoint here"]" \
          "set first breakpoint in main"
 gdb_continue_to_breakpoint "continue to first breakpoint in main"
 
-if [is_ilp32_target] {
-    set nr_regs 8
-} else {
+if [is_amd64_regs_target] {
     set nr_regs 16
+} else {
+    set nr_regs 8
 }
 
 for { set r 0 } { $r < $nr_regs } { incr r } {
diff --git a/gdb/testsuite/gdb.arch/i386-sse.exp b/gdb/testsuite/gdb.arch/i386-sse.exp
index 896faf3..4132e0c 100644
--- a/gdb/testsuite/gdb.arch/i386-sse.exp
+++ b/gdb/testsuite/gdb.arch/i386-sse.exp
@@ -73,10 +73,10 @@ gdb_test "break [gdb_get_line_number "first breakpoint here"]" \
          "set first breakpoint in main"
 gdb_continue_to_breakpoint "continue to first breakpoint in main"
 
-if [is_ilp32_target] {
-    set nr_regs 8
-} else {
+if [is_amd64_regs_target] {
     set nr_regs 16
+} else {
+    set nr_regs 8
 }
 
 for { set r 0 } { $r < $nr_regs } { incr r } {


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