diff options
author | David Taylor <taylor@redhat.com> | 1997-12-16 07:43:26 +0000 |
---|---|---|
committer | David Taylor <taylor@redhat.com> | 1997-12-16 07:43:26 +0000 |
commit | 7ae2b4337a08580658720dd758d36e80eba1ac0e (patch) | |
tree | 1ac6951f250357749dcbfb260822c3378e6be96e /gdb/config/d30v/tm-d30v.h | |
parent | eae435160e165737504d5f423a885a6ca8267fc5 (diff) | |
download | gdb-7ae2b4337a08580658720dd758d36e80eba1ac0e.zip gdb-7ae2b4337a08580658720dd758d36e80eba1ac0e.tar.gz gdb-7ae2b4337a08580658720dd758d36e80eba1ac0e.tar.bz2 |
back trace now works when using external memory and frameless functions; all
arguments are passed in args registers until we run out; finding saved regs
now has two offsets not just one doing double duty.
TARGET_READ_SP / TARGET_WRITE_SP are (temporarily?) commented out.
Diffstat (limited to 'gdb/config/d30v/tm-d30v.h')
-rw-r--r-- | gdb/config/d30v/tm-d30v.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/gdb/config/d30v/tm-d30v.h b/gdb/config/d30v/tm-d30v.h index 931c032..a1a5b58 100644 --- a/gdb/config/d30v/tm-d30v.h +++ b/gdb/config/d30v/tm-d30v.h @@ -191,8 +191,7 @@ void d30v_do_registers_info PARAMS ((int regnum, int fpregs)); /* Extract from an array REGBUF containing the (raw) register state the address in which a function should return its structure value, as a CORE_ADDR (or an expression that can be used as one). */ - -#define EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (*(CORE_ADDR *)(REGBUF)) +#define EXTRACT_STRUCT_VALUE_ADDRESS(REGBUF) (((CORE_ADDR *)(REGBUF))[2]) /* Define other aspects of the stack frame. @@ -222,8 +221,13 @@ extern void d30v_init_extra_frame_info PARAMS (( int fromleaf, struct frame_info #define FRAME_CHAIN_VALID(chain,frame) \ ((chain) != 0 && (frame) != 0 && (frame)->pc > IMEM_START) #else +#if 0 #define FRAME_CHAIN_VALID(chain,fi) \ ((chain) != 0 && (fi) != 0 && (fi)->frame <= STACK_START) +#else +#define FRAME_CHAIN_VALID(chain,fi) \ + ((chain) != 0 && (fi) != 0 && (fi)->return_pc != 0) +#endif #endif #define FRAME_SAVED_PC(FRAME) ((FRAME)->return_pc) #define FRAME_ARGS_ADDRESS(fi) (fi)->frame @@ -311,7 +315,7 @@ extern void d30v_pop_frame PARAMS((void)); #define REGISTER_SIZE 4 /* Need to handle SP special, as we need to select between spu and spi. */ - +#if 0 /* XXX until the simulator is fixed */ #define TARGET_READ_SP() ((read_register (PSW_REGNUM) & PSW_SM) \ ? read_register (SPU_REGNUM) \ : read_register (SPI_REGNUM)) @@ -319,6 +323,9 @@ extern void d30v_pop_frame PARAMS((void)); #define TARGET_WRITE_SP(val) ((read_register (PSW_REGNUM) & PSW_SM) \ ? write_register (SPU_REGNUM, (val)) \ : write_register (SPI_REGNUM, (val))) +#endif + +#define STACK_ALIGN(len) (((len) + 7 ) & ~7) /* Turn this on to cause remote-sim.c to use sim_set/clear_breakpoint. */ |