mirror of
https://github.com/ekeeke/Genesis-Plus-GX.git
synced 2024-12-30 21:21:49 +01:00
parent
14a3c5be47
commit
effdec65ed
@ -41,7 +41,6 @@
|
|||||||
/* ================================ INCLUDES ============================== */
|
/* ================================ INCLUDES ============================== */
|
||||||
/* ======================================================================== */
|
/* ======================================================================== */
|
||||||
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
#include "macros.h"
|
#include "macros.h"
|
||||||
|
|
||||||
@ -66,6 +65,7 @@
|
|||||||
#undef uint32
|
#undef uint32
|
||||||
#undef uint64
|
#undef uint64
|
||||||
#undef sint
|
#undef sint
|
||||||
|
#undef uint
|
||||||
|
|
||||||
#define sint8 signed char /* ASG: changed from char to signed char */
|
#define sint8 signed char /* ASG: changed from char to signed char */
|
||||||
#define sint16 signed short
|
#define sint16 signed short
|
||||||
@ -223,9 +223,9 @@ typedef struct
|
|||||||
/* 68k idle loop detection */
|
/* 68k idle loop detection */
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
uint32_t pc;
|
uint pc;
|
||||||
uint32_t cycle;
|
uint cycle;
|
||||||
uint32_t detected;
|
uint detected;
|
||||||
} cpu_idle_t;
|
} cpu_idle_t;
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
@ -234,38 +234,38 @@ typedef struct
|
|||||||
|
|
||||||
cpu_idle_t poll; /* polling detection */
|
cpu_idle_t poll; /* polling detection */
|
||||||
|
|
||||||
uint32_t cycles; /* current master cycle count */
|
uint cycles; /* current master cycle count */
|
||||||
uint32_t cycle_end; /* aimed master cycle count for current execution frame */
|
uint cycle_end; /* aimed master cycle count for current execution frame */
|
||||||
|
|
||||||
uint32_t dar[16]; /* Data and Address Registers */
|
uint dar[16]; /* Data and Address Registers */
|
||||||
uint32_t pc; /* Program Counter */
|
uint pc; /* Program Counter */
|
||||||
uint32_t sp[5]; /* User and Interrupt Stack Pointers */
|
uint sp[5]; /* User and Interrupt Stack Pointers */
|
||||||
uint32_t ir; /* Instruction Register */
|
uint ir; /* Instruction Register */
|
||||||
uint32_t t1_flag; /* Trace 1 */
|
uint t1_flag; /* Trace 1 */
|
||||||
uint32_t s_flag; /* Supervisor */
|
uint s_flag; /* Supervisor */
|
||||||
uint32_t x_flag; /* Extend */
|
uint x_flag; /* Extend */
|
||||||
uint32_t n_flag; /* Negative */
|
uint n_flag; /* Negative */
|
||||||
uint32_t not_z_flag; /* Zero, inverted for speedups */
|
uint not_z_flag; /* Zero, inverted for speedups */
|
||||||
uint32_t v_flag; /* Overflow */
|
uint v_flag; /* Overflow */
|
||||||
uint32_t c_flag; /* Carry */
|
uint c_flag; /* Carry */
|
||||||
uint32_t int_mask; /* I0-I2 */
|
uint int_mask; /* I0-I2 */
|
||||||
uint32_t int_level; /* State of interrupt pins IPL0-IPL2 -- ASG: changed from ints_pending */
|
uint int_level; /* State of interrupt pins IPL0-IPL2 -- ASG: changed from ints_pending */
|
||||||
uint32_t stopped; /* Stopped state */
|
uint stopped; /* Stopped state */
|
||||||
|
|
||||||
uint32_t pref_addr; /* Last prefetch address */
|
uint pref_addr; /* Last prefetch address */
|
||||||
uint32_t pref_data; /* Data in the prefetch queue */
|
uint pref_data; /* Data in the prefetch queue */
|
||||||
|
|
||||||
uint32_t instr_mode; /* Stores whether we are in instruction mode or group 0/1 exception mode */
|
uint instr_mode; /* Stores whether we are in instruction mode or group 0/1 exception mode */
|
||||||
uint32_t run_mode; /* Stores whether we are processing a reset, bus error, address error, or something else */
|
uint run_mode; /* Stores whether we are processing a reset, bus error, address error, or something else */
|
||||||
uint32_t aerr_enabled; /* Enables/deisables address error checks at runtime */
|
uint aerr_enabled; /* Enables/deisables address error checks at runtime */
|
||||||
jmp_buf aerr_trap; /* Address error jump */
|
jmp_buf aerr_trap; /* Address error jump */
|
||||||
uint32_t aerr_address; /* Address error location */
|
uint aerr_address; /* Address error location */
|
||||||
uint32_t aerr_write_mode; /* Address error write mode */
|
uint aerr_write_mode; /* Address error write mode */
|
||||||
uint32_t aerr_fc; /* Address error FC code */
|
uint aerr_fc; /* Address error FC code */
|
||||||
|
|
||||||
uint32_t tracing; /* Tracing enable flag */
|
uint tracing; /* Tracing enable flag */
|
||||||
|
|
||||||
uint32_t address_space; /* Current FC code */
|
uint address_space; /* Current FC code */
|
||||||
|
|
||||||
/* Callbacks to host */
|
/* Callbacks to host */
|
||||||
int (*int_ack_callback)(int int_line); /* Interrupt Acknowledge */
|
int (*int_ack_callback)(int int_line); /* Interrupt Acknowledge */
|
||||||
|
Loading…
Reference in New Issue
Block a user