Search
lxdream.org :: lxdream/src/sh4/sh4trans.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/sh4/sh4trans.c
changeset 1195:072131b61d2a
prev1188:1cc9bb0b3848
next1263:b3de98d19faf
author nkeynes
date Mon Dec 12 21:15:44 2011 +1000 (9 years ago)
permissions -rw-r--r--
last change Handle branch delay-slot instruction that falls on the next page correctly.
- Generate the right end PC in the first place (sh4trans.c)
- Allow blocks to be marked as both entry point + continuation, and
specifically handle invalidation when first entry of a page is a continuation ==
flush previous page as well.
file annotate diff log raw
1.1 --- a/src/sh4/sh4trans.c Thu Dec 01 01:50:44 2011 +1000
1.2 +++ b/src/sh4/sh4trans.c Mon Dec 12 21:15:44 2011 +1000
1.3 @@ -112,7 +112,7 @@
1.4 done = sh4_translate_instruction( pc );
1.5 assert( xlat_output <= eob );
1.6 pc += 2;
1.7 - if ( pc >= lastpc ) {
1.8 + if ( pc >= lastpc && done == 0 ) {
1.9 done = 2;
1.10 }
1.11 #ifdef SINGLESTEP
1.12 @@ -140,7 +140,7 @@
1.13 xlat_current_block->recover_table_offset = xlat_output - (uint8_t *)xlat_current_block->code;
1.14 xlat_current_block->recover_table_size = xlat_recovery_posn;
1.15 xlat_current_block->xlat_sh4_mode = sh4r.xlat_sh4_mode;
1.16 - xlat_commit_block( finalsize, pc-start );
1.17 + xlat_commit_block( finalsize, start, pc );
1.18 return xlat_current_block->code;
1.19 }
1.20
.