Removed speed hack - this would break the protection for lohtb2

This commit is contained in:
Couriersud 2008-10-07 23:07:09 +00:00
parent 486d9c32c0
commit 7494be5525

View File

@ -114,6 +114,10 @@ typedef UINT32 DWORD;
#include "nec.h"
#include "necintrf.h"
/* enabling USE_SPEED_HACK will break lothb2 (m72.c) protection. It may cause issues
* on any system requiring close sync between two processors */
#define USE_SPEED_HACK (0)
/* default configuration */
static const nec_config default_config =
@ -866,7 +870,9 @@ OP( 0xe8, i_call_d16 ) { UINT32 tmp; FETCHWORD(tmp); PUSH(I.ip); I.ip = (WORD)(I
OP( 0xe9, i_jmp_d16 ) { UINT32 tmp; FETCHWORD(tmp); I.ip = (WORD)(I.ip+(INT16)tmp); CHANGE_PC; nec_ICount-=15; }
OP( 0xea, i_jmp_far ) { UINT32 tmp,tmp1; FETCHWORD(tmp); FETCHWORD(tmp1); I.sregs[PS] = (WORD)tmp1; I.ip = (WORD)tmp; CHANGE_PC; nec_ICount-=27; }
OP( 0xeb, i_jmp_d8 ) { int tmp = (int)((INT8)FETCH); nec_ICount-=12;
#if USE_SPEED_HACK
if (tmp==-2 && I.no_interrupt==0 && (I.pending_irq==0) && nec_ICount>0) nec_ICount%=12; /* cycle skip */
#endif
I.ip = (WORD)(I.ip+tmp);
}
OP( 0xec, i_inaldx ) { I.regs.b[AL] = read_port_byte(I.regs.w[DW]); CLKS(8,8,5);}