Search
lxdream.org :: lxdream :: r390:d066209999f1
lxdream 0.9.1
released Jun 29
Download Now
changeset390:d066209999f1
parent389:3e354da62264
child391:16afb90b5d47
authornkeynes
dateTue Sep 18 09:12:30 2007 +0000 (12 years ago)
Ensure correct end-of-block PC
Handle syscalls
src/sh4/sh4trans.c
1.1 --- a/src/sh4/sh4trans.c Tue Sep 18 09:11:53 2007 +0000
1.2 +++ b/src/sh4/sh4trans.c Tue Sep 18 09:12:30 2007 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: sh4trans.c,v 1.2 2007-09-04 08:40:23 nkeynes Exp $
1.6 + * $Id: sh4trans.c,v 1.3 2007-09-18 09:12:30 nkeynes Exp $
1.7 *
1.8 * SH4 translation core module. This part handles the non-target-specific
1.9 * section of the translation.
1.10 @@ -48,6 +48,12 @@
1.11 }
1.12 }
1.13
1.14 + if( sh4r.pc > 0xFFFFFF00 ) {
1.15 + syscall_invoke( sh4r.pc );
1.16 + sh4r.in_delay_slot = 0;
1.17 + sh4r.pc = sh4r.pr;
1.18 + }
1.19 +
1.20 gboolean (*code)() = xlat_get_code(sh4r.pc);
1.21 if( code == NULL ) {
1.22 code = sh4_translate_basic_block( sh4r.pc );
1.23 @@ -97,6 +103,7 @@
1.24 }
1.25 pc += 2;
1.26 }
1.27 + pc+=2;
1.28 sh4_translate_end_block(pc);
1.29 xlat_commit_block( xlat_output - block->code, pc-start );
1.30 return block->code;
.