diff options
author | DJ Delorie <dj@redhat.com> | 2010-07-29 18:41:28 +0000 |
---|---|---|
committer | DJ Delorie <dj@redhat.com> | 2010-07-29 18:41:28 +0000 |
commit | f9c7014e9c1c8ac8b39b1819a6510d0a2ba90e13 (patch) | |
tree | a760f9b77fd6470565431634077188b206488346 /sim/rx/cpu.h | |
parent | d0d995612d39d0be3e1629f07e524f219e90b92e (diff) | |
download | gdb-f9c7014e9c1c8ac8b39b1819a6510d0a2ba90e13.zip gdb-f9c7014e9c1c8ac8b39b1819a6510d0a2ba90e13.tar.gz gdb-f9c7014e9c1c8ac8b39b1819a6510d0a2ba90e13.tar.bz2 |
[include/opcode]
* rx.h (RX_Operand_Type): Add TwoReg.
(RX_Opcode_ID): Remove ediv and ediv2.
[opcodes]
* rx-decode.opc (SRR): New.
(rx_decode_opcode): Use it for movbi and movbir. Decode NOP2 (mov
r0,r0) and NOP3 (max r0,r0) special cases.
* rx-decode.c: Regenerate.
[sim/rx]
* rx.c (decode_cache_base): New.
(id_names): Remove ediv and edivu.
(optype_names): Add TwoReg.
(maybe_get_mem_page): New.
(rx_get_byte): Call it.
(get_op): Add TwoReg support.
(put_op): Likewise.
(PD, PS, PS2, GD, GS, GS2, DSZ, SSZ, S2SZ, US1, US2, OM): "opcode"
is a pointer now.
(DO_RETURN): New. We use longjmp to return an exception result.
(decode_opcode): Make opcode a pointer to the decode cache. Save
decoded opcode information and re-use. Call DO_RETURN instead of
return throughout. Remove ediv and edivu.
* mem.c (ptdc): New. Adds decode cache.
(rx_mem_ptr): Support it.
(rx_mem_decode_cache): New.
* mem.h (enum mem_ptr_action): add MPA_DECODE_CACHE.
(rx_mem_decode_cache): Declare.
* gdb-if.c (sim_resume): Add decode_opcode's setjmp logic here...
* main.c (main): ...and here. Use a fast loop if neither trace
nor disassemble is given.
* cpu.h (RX_MAKE_STEPPED, RX_MAKE_HIT_BREAK, RX_MAKE_EXITED,
RX_MAKE_STOPPED, RX_EXITED, RX_STOPPED): Adjust so that 0 is not a
valid code for anything.
Diffstat (limited to 'sim/rx/cpu.h')
-rw-r--r-- | sim/rx/cpu.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sim/rx/cpu.h b/sim/rx/cpu.h index 74ab4b6..37ca7f8 100644 --- a/sim/rx/cpu.h +++ b/sim/rx/cpu.h @@ -211,16 +211,16 @@ int condition_true (int cond_id); - RX_MAKE_HIT_BREAK is the return code for hitting a breakpoint. - RX_MAKE_EXITED (C) is the return code for exiting with status C. - RX_MAKE_STOPPED (S) is the return code for stopping on signal S. */ -#define RX_MAKE_STEPPED() (0) -#define RX_MAKE_HIT_BREAK() (1) -#define RX_MAKE_EXITED(c) (((int) (c) << 8) + 2) -#define RX_MAKE_STOPPED(s) (((int) (s) << 8) + 3) +#define RX_MAKE_STEPPED() (1) +#define RX_MAKE_HIT_BREAK() (2) +#define RX_MAKE_EXITED(c) (((int) (c) << 8) + 3) +#define RX_MAKE_STOPPED(s) (((int) (s) << 8) + 4) #define RX_STEPPED(r) ((r) == RX_MAKE_STEPPED ()) #define RX_HIT_BREAK(r) ((r) == RX_MAKE_HIT_BREAK ()) -#define RX_EXITED(r) (((r) & 0xff) == 2) +#define RX_EXITED(r) (((r) & 0xff) == 3) #define RX_EXIT_STATUS(r) ((r) >> 8) -#define RX_STOPPED(r) (((r) & 0xff) == 3) +#define RX_STOPPED(r) (((r) & 0xff) == 4) #define RX_STOP_SIG(r) ((r) >> 8) /* The step result for the current step. Global to allow |