1.1 --- a/src/sh4/sh4trans.c Tue Jan 15 20:50:23 2008 +0000
1.2 +++ b/src/sh4/sh4trans.c Wed Jan 16 09:37:08 2008 +0000
1.4 xlat_output = (uint8_t *)block->code;
1.5 xlat_recovery_posn = 0;
1.6 uint8_t *eob = xlat_output + block->size;
1.8 + if( GET_ICACHE_END() < lastpc ) {
1.9 + lastpc = GET_ICACHE_END();
1.12 sh4_translate_begin_block(pc);
1.15 @@ -251,25 +256,27 @@
1.17 void *result = NULL;
1.19 - if( !IS_IN_ICACHE(vma) ) {
1.20 - if( vma > 0xFFFFFF00 ) {
1.24 - if( !mmu_update_icache(sh4r.pc) ) {
1.25 - // fault - off to the fault handler
1.26 - if( !mmu_update_icache(sh4r.pc) ) {
1.27 - // double fault - halt
1.28 - ERROR( "Double fault - halting" );
1.34 - if( sh4_icache.page_vma != -1 ) {
1.35 + if( IS_IN_ICACHE(vma) ) {
1.36 result = xlat_get_code( GET_ICACHE_PHYS(vma) );
1.39 + if( vma > 0xFFFFFF00 ) {
1.44 + if( !mmu_update_icache(vma) ) {
1.45 + // fault - off to the fault handler
1.46 + if( !mmu_update_icache(sh4r.pc) ) {
1.47 + // double fault - halt
1.48 + ERROR( "Double fault - halting" );
1.54 + assert( IS_IN_ICACHE(sh4r.pc) );
1.55 + result = xlat_get_code( GET_ICACHE_PHYS(sh4r.pc) );