Search
lxdream.org :: lxdream/src/sh4/sh4x86.in :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/sh4/sh4x86.in
changeset 1214:49152b3d8b75
prev1198:407659e01ef0
next1216:defbd44429d8
author nkeynes
date Mon Feb 13 12:27:09 2012 +1000 (10 years ago)
permissions -rw-r--r--
last change Setup the unlink_blocks function via a callback, rather than calling
directly into sh4/x86 code from xltcache
file annotate diff log raw
1.1 --- a/src/sh4/sh4x86.in Fri Dec 16 10:08:45 2011 +1000
1.2 +++ b/src/sh4/sh4x86.in Mon Feb 13 12:27:09 2012 +1000
1.3 @@ -122,6 +122,7 @@
1.4 static uint32_t trunc_fcw = 0x0F7F; /* fcw value for truncation mode */
1.5
1.6 static void FASTCALL sh4_translate_get_code_and_backpatch( uint32_t pc );
1.7 +static void sh4_x86_translate_unlink_block( void *use_list );
1.8
1.9 static struct x86_symbol x86_symbol_table[] = {
1.10 { "sh4r+128", ((char *)&sh4r)+128 },
1.11 @@ -144,6 +145,10 @@
1.12 { "xlat_get_code", xlat_get_code }
1.13 };
1.14
1.15 +static struct xlat_target_fns x86_target_fns = {
1.16 + sh4_x86_translate_unlink_block
1.17 +};
1.18 +
1.19
1.20 gboolean is_sse3_supported()
1.21 {
1.22 @@ -175,6 +180,7 @@
1.23 sh4_x86.sse3_enabled = is_sse3_supported();
1.24 x86_disasm_init();
1.25 x86_set_symtab( x86_symbol_table, sizeof(x86_symbol_table)/sizeof(struct x86_symbol) );
1.26 + xlat_set_target_fns(x86_target_fns);
1.27 }
1.28
1.29 void sh4_translate_set_callbacks( xlat_block_begin_callback_t begin, xlat_block_end_callback_t end )
1.30 @@ -652,7 +658,7 @@
1.31
1.32 }
1.33
1.34 -void sh4_translate_unlink_block( void *use_list )
1.35 +static void sh4_x86_translate_unlink_block( void *use_list )
1.36 {
1.37 uint8_t *tmp = xlat_output; /* In case something is active, which should never happen */
1.38 void *next = use_list;
.