diff options
author | Daniel Jacobowitz <drow@false.org> | 2007-06-13 18:27:00 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2007-06-13 18:27:00 +0000 |
commit | f8b73d13b7ca749dee450b60e4e401b4c096bed6 (patch) | |
tree | 6ecc1a4f231e32c4d57405f6c4173ce2d48d5fcf /gdb/testsuite/gdb.xml | |
parent | 17a912b6825ef7feaad6d9b4f5419f045fe3c8d0 (diff) | |
download | gdb-f8b73d13b7ca749dee450b60e4e401b4c096bed6.zip gdb-f8b73d13b7ca749dee450b60e4e401b4c096bed6.tar.gz gdb-f8b73d13b7ca749dee450b60e4e401b4c096bed6.tar.bz2 |
* Makefile.in (mips-tdep.o): Update.
* mips-tdep.c (struct register_alias, mips_o32_aliases)
(mips_n32_n64_aliases, mips_register_aliases): New.
(mips_register_name): Call tdesc_register_name.
(mips_tdesc_register_reggroup_p): New.
(mips_pseudo_register_type, value_of_mips_user_reg): New.
(mips_gdbarch_init): Add target-described register support.
Register aliases for register names.
* target-descriptions.c (tdesc_register_name): Make global.
(tdesc_register_in_reggroup_p): New function, broken out from
tdesc_register_reggroup_p.
(tdesc_register_reggroup_p): Use it.
* target-descriptions.h (tdesc_register_name)
(tdesc_register_in_reggroup_p): New prototypes.
* NEWS: Correct formatting. Mention MIPS register support.
* features/mips-cp0.xml, features/mips-fpu.xml,
features/mips64-cp0.xml, gdb/features/mips64-fpu.xml, mips-cpu.xml,
features/mips64-cpu.xml: New files.
* gdb.xml/tdesc-regs.exp: Add MIPS support. Allow multiple
required features to be included.
* gdb.texinfo (MIPS Features): New subsection.
Diffstat (limited to 'gdb/testsuite/gdb.xml')
-rw-r--r-- | gdb/testsuite/gdb.xml/tdesc-regs.exp | 32 |
1 files changed, 26 insertions, 6 deletions
diff --git a/gdb/testsuite/gdb.xml/tdesc-regs.exp b/gdb/testsuite/gdb.xml/tdesc-regs.exp index fde2111..43d6c99 100644 --- a/gdb/testsuite/gdb.xml/tdesc-regs.exp +++ b/gdb/testsuite/gdb.xml/tdesc-regs.exp @@ -27,10 +27,13 @@ gdb_start set core-regs "" switch -glob -- [istarget] { "*arm-*-*" { - set core-regs arm-core + set core-regs {arm-core.xml} } "xscale-*-*" { - set core-regs arm-core + set core-regs {arm-core.xml} + } + "mips*-*-*" { + set core-regs {mips-cpu.xml mips-cp0.xml mips-fpu.xml} } } @@ -56,17 +59,32 @@ gdb_test "set tdesc file $srcdir/$subdir/single-reg.xml" \ # Copy the core registers into the objdir if necessary, so that they # will be found by <xi:include>. -file delete "core-regs.xml" -file copy "$srcdir/../features/${core-regs}.xml" "core-regs.xml" +foreach src ${core-regs} { + file delete "$src" + file copy "$srcdir/../features/$src" "$src" +} # Similarly, we need to copy files under test into the objdir. proc load_description { file errmsg } { global srcdir global subdir global gdb_prompt + global core-regs file delete "regs.xml" - file copy "$srcdir/$subdir/$file" "regs.xml" + set ifd [open "$srcdir/$subdir/$file" r] + set ofd [open "regs.xml" w] + while {[gets $ifd line] >= 0} { + if {[regexp {<xi:include href="core-regs.xml"/>} $line]} { + foreach src ${core-regs} { + puts $ofd " <xi:include href=\"$src\"/>" + } + } else { + puts $ofd $line + } + } + close $ifd + close $ofd # Anchor the test output, so that error messages are detected. set cmd "set tdesc filename regs.xml" @@ -91,5 +109,7 @@ load_description "core-only.xml" "" # The extra register from the previous description should be gone. gdb_test "ptype \$extrareg" "type = void" -file delete "core-regs.xml" +foreach src ${core-regs} { + file delete "$src" +} file delete "regs.xml" |