sim: replace CIA_{GET,SET} with CPU_PC_{GET,SET}

The CIA_{GET,SET} macros serve the same function as CPU_PC_{GET,SET}
except the latter adds a layer of indirection via the sim state.  This
lets models set up different functions at runtime and doesn't reach so
directly into the arch-specific cpu state.

It also doesn't make sense to have two sets of macros that do exactly
the same thing, so lets standardize on the one that gets us more.
This commit is contained in:
Mike Frysinger
2015-04-16 02:11:12 -04:00
parent 27b97b40bc
commit 034685f9ce
64 changed files with 184 additions and 116 deletions

View File

@ -257,8 +257,6 @@ struct _sim_cpu {
/* The following are internal simulator state variables: */
#define CIA_GET(CPU) ((CPU)->registers[PCIDX] + 0)
#define CIA_SET(CPU,CIA) ((CPU)->registers[PCIDX] = (CIA))
address_word dspc; /* delay-slot PC */
#define DSPC ((CPU)->dspc)