This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH, testsuite] Don't run SREC, IHEX and TEKHEX tests for MIPS N64.
- From: Luis Machado <lgustavo at codesourcery dot com>
- To: "'gdb-patches at sourceware dot org'" <gdb-patches at sourceware dot org>
- Date: Mon, 01 Jul 2013 13:24:35 -0300
- Subject: [PATCH, testsuite] Don't run SREC, IHEX and TEKHEX tests for MIPS N64.
- Reply-to: lgustavo at codesourcery dot com
Hi,
The gdb.base/dump.exp test had a few failures for MIPS N64. That is
expected since SREC, IHEX and TEKHEX dump formats don't support 64-bit
addresses, and MIPS N64 uses them.
Skipping this test for MIPS is not the right thing as some ABI's are
32-bit and so should be tested against the usual set of SREC, IHEX and
TEKHEX formats.
The attached patch checks for the N64 ABI and sets the internal flag
is64bitonly accordingly, skipping the SREC, IHEX and TEKHEX tests.
Ok?
2013-07-01 Luis Machado <lgustavo@codesourcery.com>
* gdb.base/dump.exp: Don't run SREC, IHEX and TEKHEX dump
tests for mips N64 ABI.
Index: gdb/testsuite/gdb.base/dump.exp
===================================================================
--- gdb/testsuite/gdb.base/dump.exp (revision 415809)
+++ gdb/testsuite/gdb.base/dump.exp (working copy)
@@ -58,6 +58,17 @@
gdb_load ${binfile}
+# Since SREC, IHEX and TEKHEX cannot handle 64-bit addresses for
+# MIPS64, stop testing if we have a 64-bit MIPS program.
+if {[istarget "mips*-*-*"]} then {
+ send_gdb "show mips abi\n"
+ gdb_expect {
+ -re ".*n64.*$gdb_prompt $" {
+ set is64bitonly "yes"
+ }
+ }
+}
+
# Clean up any stale output files from previous test runs
remote_exec build "rm -f intarr1.bin intarr1b.bin intarr1.ihex intarr1.srec intarr1.tekhex intarr2.bin intarr2b.bin intarr2.ihex intarr2.srec intarr2.tekhex intstr1.bin intstr1b.bin intstr1.ihex intstr1.srec intstr1.tekhex intstr2.bin intstr2b.bin intstr2.ihex intstr2.srec intstr2.tekhex intarr3.srec"