summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--m68k_to_x86.c7
-rw-r--r--x86_backend.h26
2 files changed, 25 insertions, 8 deletions
diff --git a/m68k_to_x86.c b/m68k_to_x86.c
index b897540..c0a0034 100644
--- a/m68k_to_x86.c
+++ b/m68k_to_x86.c
@@ -4345,13 +4345,6 @@ void m68k_reset(m68k_context * context)
start_68k_context(context, address);
}
-typedef enum {
- READ_16,
- READ_8,
- WRITE_16,
- WRITE_8
-} ftype;
-
uint8_t * gen_mem_fun(x86_68k_options * opts, memmap_chunk * memmap, uint32_t num_chunks, ftype fun_type)
{
uint8_t * dst = opts->cur_code;
diff --git a/x86_backend.h b/x86_backend.h
index 57c1e21..c556800 100644
--- a/x86_backend.h
+++ b/x86_backend.h
@@ -1,6 +1,6 @@
/*
Copyright 2013 Michael Pavone
- This file is part of BlastEm.
+ This file is part of BlastEm.
BlastEm is free software distributed under the terms of the GNU General Public License version 3 or greater. See COPYING for full license text.
*/
#ifndef X86_BACKEND_H_
@@ -30,6 +30,30 @@ typedef struct deferred_addr {
uint32_t address;
} deferred_addr;
+typedef enum {
+ READ_16,
+ READ_8,
+ WRITE_16,
+ WRITE_8
+} ftype;
+
+typedef struct {
+ uint32_t flags;
+ 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 *save_context;
+ uint8_t *load_context;
+ uint8_t *handle_cycle_limit;
+ uint8_t *handle_cycle_limit_int;
+ uint8_t context_reg;
+ uint8_t scratch1;
+ uint8_t scratch2;
+} cpu_options;
+
#define MMAP_READ 0x01
#define MMAP_WRITE 0x02