diff options
author | Andrew Cagney <cagney@redhat.com> | 2002-05-29 16:39:56 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 2002-05-29 16:39:56 +0000 |
commit | 0b6a2b5d50aa52f9df12fa1392134dd22f1eaaf1 (patch) | |
tree | dfe1593100e7d7ba62dd47535d454fab7c3617d0 /gdb/arch-utils.c | |
parent | 969d24233c8d0ae64d221ae235ed1b8cb0aef4a8 (diff) | |
download | gdb-0b6a2b5d50aa52f9df12fa1392134dd22f1eaaf1.tar.gz |
* Makefile.in (arch-utils.o): Add $(sim_regno_h).
* arch-utils.c: Include "sim-regno.h".
* gdbarch.sh: Don't include "sim-regno.h".
* gdbarch.h, gdbarch.c: Regenerate.
* sim-regno.h (legacy_register_sim_regno): Move declaration from
here.
* arch-utils.h (legacy_register_sim_regno): To here.
* remote-sim.c (legacy_register_sim_regno): Move function from
here.
* arch-utils.c (legacy_register_sim_regno): To here.
Diffstat (limited to 'gdb/arch-utils.c')
-rw-r--r-- | gdb/arch-utils.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c index 5d13a2dd1ad..8e69a6127ad 100644 --- a/gdb/arch-utils.c +++ b/gdb/arch-utils.c @@ -42,6 +42,7 @@ #endif #include "regcache.h" #include "gdb_assert.h" +#include "sim-regno.h" #include "version.h" @@ -91,6 +92,22 @@ legacy_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr) } int +legacy_register_sim_regno (int regnum) +{ + /* Only makes sense to supply raw registers. */ + gdb_assert (regnum >= 0 && regnum < NUM_REGS); + /* NOTE: cagney/2002-05-13: The old code did it this way and it is + suspected that some GDB/SIM combinations may rely on this + behavour. The default should be one2one_register_sim_regno + (below). */ + if (REGISTER_NAME (regnum) != NULL + && REGISTER_NAME (regnum)[0] != '\0') + return regnum; + else + return LEGACY_SIM_REGNO_IGNORE; +} + +int generic_frameless_function_invocation_not (struct frame_info *fi) { return 0; |