forked from Imagelibrary/binutils-gdb
sim: watchpoints: use common sim_pc_get
Few arches implement STATE_WATCHPOINTS()->pc while all of them implement sim_pc_get. Lets switch the sim-watch core for monitoring pc events to the sim_pc_get API so this module works for all ports, and then we can delete this old back channel of snooping in the port's cpu state -- the code needs the pointer to the pc storage so that it can read out bytes and compare them to the watchrange. This also fixes the logic on multi-cpu sims by removing the limitation of only being able to watch CPU0's state.
This commit is contained in:
@@ -355,7 +355,6 @@ sim_open (SIM_OPEN_KIND kind, host_callback *cb,
|
||||
cpu = STATE_CPU (sd, 0); /* FIXME */
|
||||
|
||||
/* FIXME: watchpoints code shouldn't need this */
|
||||
STATE_WATCHPOINTS (sd)->pc = &(PC);
|
||||
STATE_WATCHPOINTS (sd)->interrupt_handler = interrupt_event;
|
||||
|
||||
/* Initialize the mechanism for doing insn profiling. */
|
||||
|
||||
Reference in New Issue
Block a user