diff options
author | Jim Blandy <jimb@codesourcery.com> | 1999-02-01 21:17:19 +0000 |
---|---|---|
committer | Jim Blandy <jimb@codesourcery.com> | 1999-02-01 21:17:19 +0000 |
commit | 2ac058fda90201dbc931cd0d2d94c1b4f62d78a8 (patch) | |
tree | c19f000c273aed76748764472c17cea1ebc8cfb6 /gdb/configure.in | |
parent | e745689c957be21abe278ae81d7a1b12fab9b27a (diff) | |
download | gdb-2ac058fda90201dbc931cd0d2d94c1b4f62d78a8.zip gdb-2ac058fda90201dbc931cd0d2d94c1b4f62d78a8.tar.gz gdb-2ac058fda90201dbc931cd0d2d94c1b4f62d78a8.tar.bz2 |
Allow PPC users to select which PPC/RS6000 variant they're debugging
at run-time. At the moment, the only thing this affects is the
set of registers visible.
* config/rs6000/tm-rs6000.h (REGISTER_NAME): Define this as a call
to the function rs6000_register_name.
(rs6000_register_name): Include extern decl.
(NUM_REGS): Bump to 183. What's the right way to do this?
(FIRST_UISA_SP_REGNUM, LAST_UISA_SP_REGNUM): Renamed from
FIRST_SP_REGNUM, LAST_SP_REGNUM.
(REGISTER_BYTES): Recompute this.
* rs6000-tdep.c: Renamed all uses of FIRST_SP_REGNUM and
LAST_SP_REGNUM to FIRST_UISA_SP_REGNUM and LAST_UISA_SP_REGNUM, with
some concomitant formatting changes.
#include "gdbcmd.h", so we can define commands here.
(struct variant): New structure.
(COMMON_UISA_REG_NAMES, PPC_UISA_SPR_NAMES, PPC_SEGMENT_REG_NAMES,
PPC_32_OEA_SPR_NAMES, num_registers): New macros.
(register_names_rs6000, register_names_uisa, register_names_403,
register_names_403GC, register_names_505, register_names_860,
register_names_601, register_names_602, register_names_603,
register_names_604, register_names_750, variants): New variables.
(rs6000_register_name, install_variant, find_variant_by_name,
install_variant_by_name, list_variants, show_current_variant,
set_processor, show_processor): New functions.
(_initialize_rs6000_tdep): Define new commands `set processor' and
`show processor', and call install_variant_by_name to set the
default variant.
* rs6000-nat.c: Renamed all uses of FIRST_SP_REGNUM and
LAST_SP_REGNUM to FIRST_UISA_SP_REGNUM and LAST_UISA_SP_REGNUM, with
some concomitant formatting changes.
* configure.in: Accept the `--with-cpu' flag, to specify a default
processor variant.
* acconfig.h: Provide a blurb for TARGET_CPU_DEFAULT, which is set
by configure's `--with-cpu' flag.
* config.in, configure: Regenerated.
Diffstat (limited to 'gdb/configure.in')
-rw-r--r-- | gdb/configure.in | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/gdb/configure.in b/gdb/configure.in index be68643..c9c3a54 100644 --- a/gdb/configure.in +++ b/gdb/configure.in @@ -561,6 +561,42 @@ AC_SUBST(LIBIDE) AC_SUBST(IDE_DEPS) # end-sanitize-ide + +AC_ARG_WITH(cpu, +[ --with-cpu=CPU set the default CPU variant to debug], +[case "${target}" in + powerpc-* | powerpcle-* ) + ## It would be nice to keep this table in sync with the one in + ## gcc/configure. + case "${with_cpu}" in + ppc-uisa | rs6000 | 403 | 403GC | 505 | 860 | 601 | 602 | 603 \ + | 604 | 750 ) + ## Those are all handled in variants in rs6000-tdep.c, so they're fine. + ;; + common | power | power2 | rios | rios1 | rios2 | rsc | rsc1 ) + ## These are all RS6000 variants, as far as GDB is concerned. + with_cpu=rs6000 + ;; + 603e | ec603e ) + with_cpu=603 + ;; + 604e ) + with_cpu=604 + ;; + * ) + AC_MSG_WARN(GDB: unknown --with-cpu value: \`${with_cpu}'; using \`ppc-uisa'.) + with_cpu=ppc-uisa + ;; + esac + ;; + * ) + AC_MSG_WARN(GDB may ignore the --with-cpu flag for ${target} targets) + ;; +esac +AC_DEFINE_UNQUOTED(TARGET_CPU_DEFAULT, "${with_cpu}") +],) + + ENABLE_GDBTK= AC_ARG_ENABLE(gdbtk, |