From 16e7b59467ba17034f63834962e5d326a8facce4 Mon Sep 17 00:00:00 2001 From: Michael Pavone Date: Sun, 2 Mar 2014 14:45:36 -0800 Subject: Refactor gen_x86 to use an interface more like gen_arm and to remove the need for the caller to decide whether an 8-bit or 32-bit displacement is needed in the rdisp functions. Update m68k_to_x86 to use the new version of the gen_x86 functions and do some minor refactoring there in the process --- trans.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'trans.c') diff --git a/trans.c b/trans.c index ac4bf22..285fe73 100644 --- a/trans.c +++ b/trans.c @@ -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. */ #include "68kinst.h" @@ -43,14 +43,14 @@ int main(int argc, char ** argv) memmap[0].mask = 0xFFFFFF; memmap[0].flags = MMAP_READ; memmap[0].buffer = filebuf; - + memmap[1].start = 0xE00000; memmap[1].end = 0x1000000; memmap[1].mask = 0xFFFF; memmap[1].flags = MMAP_READ | MMAP_WRITE | MMAP_CODE; memmap[1].buffer = malloc(64 * 1024); init_x86_68k_opts(&opts, memmap, 2); - init_68k_context(&context, opts.native_code_map, &opts); + init_68k_context(&context, opts.gen.native_code_map, &opts); context.mem_pointers[0] = memmap[0].buffer; context.mem_pointers[1] = memmap[1].buffer; context.target_cycle = context.sync_cycle = 0x80000000; -- cgit v1.2.3