summaryrefslogtreecommitdiff
path: root/m68k_to_x86.h
diff options
context:
space:
mode:
authorMike Pavone <pavone@retrodev.com>2014-02-24 01:30:16 -0800
committerMike Pavone <pavone@retrodev.com>2014-02-24 01:30:16 -0800
commit14c0b3e916d866601311f9bbe53ab64ed560f67f (patch)
tree015e3c591d1c092c20bbc940f0e1b5d10be4a9c6 /m68k_to_x86.h
parentfcf5fcfccb16b87e69b3ce9dd8dc74dbbaf426db (diff)
Use a typedef code_ptr in place of uint8_t * in 68K core to better support host instruction sets with different instruction word sizes. Make x86_68k_options contain a cpu_options so that gen_mem_fun can eventually be shared with the Z80 core.
Diffstat (limited to 'm68k_to_x86.h')
-rw-r--r--m68k_to_x86.h42
1 files changed, 17 insertions, 25 deletions
diff --git a/m68k_to_x86.h b/m68k_to_x86.h
index 7752465..c4fbf22 100644
--- a/m68k_to_x86.h
+++ b/m68k_to_x86.h
@@ -19,36 +19,28 @@ struct m68kinst;
typedef void (*start_fun)(uint8_t * addr, void * context);
typedef struct {
- uint32_t flags;
+ cpu_options gen;
+
int8_t dregs[8];
int8_t aregs[8];
int8_t flag_regs[5];
- native_map_slot *native_code_map;
- deferred_addr *deferred;
- uint8_t *cur_code;
- uint8_t *code_end;
- uint8_t **ram_inst_sizes;
FILE *address_log;
- uint8_t *read_16;
- uint8_t *write_16;
- uint8_t *read_8;
- uint8_t *write_8;
- uint8_t *read_32;
- uint8_t *write_32_lowfirst;
- uint8_t *write_32_highfirst;
- uint8_t *handle_cycle_limit;
- uint8_t *handle_cycle_limit_int;
- uint8_t *do_sync;
- uint8_t *trap;
- uint8_t *save_context;
- uint8_t *load_context;
+ code_ptr read_16;
+ code_ptr write_16;
+ code_ptr read_8;
+ code_ptr write_8;
+ code_ptr read_32;
+ code_ptr write_32_lowfirst;
+ code_ptr write_32_highfirst;
+ code_ptr do_sync;
+ code_ptr trap;
start_fun start_context;
- uint8_t *retrans_stub;
- uint8_t *native_addr;
- uint8_t *native_addr_and_sync;
- uint8_t *get_sr;
- uint8_t *set_sr;
- uint8_t *set_ccr;
+ code_ptr retrans_stub;
+ code_ptr native_addr;
+ code_ptr native_addr_and_sync;
+ code_ptr get_sr;
+ code_ptr set_sr;
+ code_ptr set_ccr;
} x86_68k_options;
typedef struct {