X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=cpu%2Ffame%2Ffame.h;h=93172c8747fc95ca74d509b87e5f726319347594;hb=12f23dac6f91eb707f985ef00a5d48e9e5ef8838;hp=d5349246f83bb443c677c53a4ba80305c4b044dc;hpb=95049eea1c93ae4ed044c0cbb51b3c19442e0e2b;p=picodrive.git diff --git a/cpu/fame/fame.h b/cpu/fame/fame.h index d534924..93172c8 100644 --- a/cpu/fame/fame.h +++ b/cpu/fame/fame.h @@ -125,6 +125,7 @@ typedef struct unsigned int Opcode; signed int cycles_needed; + unsigned short *PC; unsigned long BasePC; unsigned int flag_C; @@ -136,23 +137,37 @@ typedef struct unsigned int flag_S; unsigned int flag_I; + unsigned char not_polling; + unsigned char pad[3]; + unsigned long Fetch[M68K_FETCHBANK1]; } M68K_CONTEXT; extern M68K_CONTEXT *g_m68kcontext; +typedef enum +{ + fm68k_reason_emulate = 0, + fm68k_reason_init, + fm68k_reason_idle_install, + fm68k_reason_idle_remove, +} fm68k_call_reason; + /************************/ /* Function definition */ /************************/ /* General purpose functions */ void fm68k_init(void); -int fm68k_reset(void); -int fm68k_emulate(int n, int dualcore, int idle_mode); -int fm68k_would_interrupt(void); // to be called from fm68k_emulate() +int fm68k_reset(M68K_CONTEXT *ctx); +int fm68k_emulate(M68K_CONTEXT *ctx, int n, fm68k_call_reason reason); +int fm68k_would_interrupt(M68K_CONTEXT *ctx); // to be called from fm68k_emulate() -unsigned fm68k_get_pc(M68K_CONTEXT *context); +unsigned fm68k_get_pc(M68K_CONTEXT *ctx); +// PICODRIVE_HACK +int fm68k_idle_install(void); +int fm68k_idle_remove(void); #ifdef __cplusplus }