From 1a6a13680119d40bb20f1bd8a7e62a76c6b16d58 Mon Sep 17 00:00:00 2001 From: aliaspider Date: Tue, 9 Dec 2014 09:54:33 +0100 Subject: dynamic recompiler now works when the core is compiled as a shared library. --- cpu_threaded.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'cpu_threaded.c') diff --git a/cpu_threaded.c b/cpu_threaded.c index db7155c..a490e38 100644 --- a/cpu_threaded.c +++ b/cpu_threaded.c @@ -23,18 +23,27 @@ #include "common.h" +#ifdef __LIBRETRO__ +u8* rom_translation_cache; +u8* ram_translation_cache; +u8* bios_translation_cache; +u8 *rom_translation_ptr; +u8 *ram_translation_ptr; +u8 *bios_translation_ptr; +#else u8 rom_translation_cache[ROM_TRANSLATION_CACHE_SIZE]; -u8 *rom_translation_ptr = rom_translation_cache; - u8 ram_translation_cache[RAM_TRANSLATION_CACHE_SIZE]; +u8 bios_translation_cache[BIOS_TRANSLATION_CACHE_SIZE]; +u8 *rom_translation_ptr = rom_translation_cache; u8 *ram_translation_ptr = ram_translation_cache; +u8 *bios_translation_ptr = bios_translation_cache; +#endif + u32 iwram_code_min = 0xFFFFFFFF; u32 iwram_code_max = 0xFFFFFFFF; u32 ewram_code_min = 0xFFFFFFFF; u32 ewram_code_max = 0xFFFFFFFF; -u8 bios_translation_cache[BIOS_TRANSLATION_CACHE_SIZE]; -u8 *bios_translation_ptr = bios_translation_cache; u32 *rom_branch_hash[ROM_BRANCH_HASH_SIZE]; -- cgit v1.2.3