Added some exceptions for illegal opcodes.
Double 0x67 prefixes should work now. Thnx c2woody Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@1688
This commit is contained in:
parent
e8913d4dd2
commit
410b9f72d2
3 changed files with 11 additions and 3 deletions
|
@ -94,8 +94,8 @@ extern Bitu cycle_count;
|
|||
core.seg_prefix_base=SegBase(_SEG); \
|
||||
goto restart_prefix;
|
||||
|
||||
#define DO_PREFIX_ADDR() \
|
||||
core.prefixes^=PREFIX_ADDR; \
|
||||
#define DO_PREFIX_ADDR() \
|
||||
core.prefixes|=(core.prefix_default ^ PREFIX_ADDR) & PREFIX_ADDR; \
|
||||
goto restart_prefix;
|
||||
|
||||
#define DO_PREFIX_REP(_ZERO) \
|
||||
|
@ -194,9 +194,15 @@ restart_opcode:
|
|||
#endif
|
||||
}
|
||||
}
|
||||
decode_end:
|
||||
decode_end:
|
||||
LEAVECORE;
|
||||
return CBRET_NONE;
|
||||
|
||||
illegal_opcode:
|
||||
LEAVECORE;
|
||||
reg_eip-=core.ip_lookup-core.op_start;
|
||||
CPU_Exception(6,0);
|
||||
goto decode_start;
|
||||
}
|
||||
|
||||
Bits CPU_Core_Normal_Trap_Run(void) {
|
||||
|
|
|
@ -167,6 +167,7 @@
|
|||
break;
|
||||
CASE_D(0x63) /* ARPL Ed,Rd */
|
||||
{
|
||||
if (((cpu.pmode) && (reg_flags & FLAG_VM)) || (!cpu.pmode)) goto illegal_opcode;
|
||||
FillFlags();
|
||||
GetRMrw;
|
||||
if (rm >= 0xc0 ) {
|
||||
|
|
|
@ -237,6 +237,7 @@
|
|||
break;
|
||||
CASE_W(0x63) /* ARPL Ew,Rw */
|
||||
{
|
||||
if (((cpu.pmode) && (reg_flags & FLAG_VM)) || (!cpu.pmode)) goto illegal_opcode;
|
||||
FillFlags();
|
||||
GetRMrw;
|
||||
if (rm >= 0xc0 ) {
|
||||
|
|
Loading…
Add table
Reference in a new issue