All six MOV memory,immadiate instruction variants now perform segment limit checks, 86Box now passes all TEST386 tests.

This commit is contained in:
OBattler
2018-07-24 23:57:17 +02:00
parent bdff70c322
commit d9357d2f8b

View File

@@ -195,6 +195,7 @@ static int opMOV_b_imm_a32(uint32_t fetchdat)
fetch_ea_32(fetchdat);
ILLEGAL_ON((rmdat & 0x38) != 0);
temp = getbyte(); if (cpu_state.abrt) return 1;
CHECK_WRITE(cpu_state.ea_seg, cpu_state.eaaddr, cpu_state.eaaddr);
seteab(temp);
CLOCK_CYCLES(timing_rr);
PREFETCH_RUN(timing_rr, 3, rmdat, 0,0,(cpu_mod == 3) ? 1:0,0, 1);
@@ -207,6 +208,7 @@ static int opMOV_w_imm_a16(uint32_t fetchdat)
fetch_ea_16(fetchdat);
ILLEGAL_ON((rmdat & 0x38) != 0);
temp = getword(); if (cpu_state.abrt) return 1;
CHECK_WRITE(cpu_state.ea_seg, cpu_state.eaaddr, cpu_state.eaaddr + 1);
seteaw(temp);
CLOCK_CYCLES(timing_rr);
PREFETCH_RUN(timing_rr, 4, rmdat, 0,0,(cpu_mod == 3) ? 1:0,0, 0);
@@ -218,6 +220,7 @@ static int opMOV_w_imm_a32(uint32_t fetchdat)
fetch_ea_32(fetchdat);
ILLEGAL_ON((rmdat & 0x38) != 0);
temp = getword(); if (cpu_state.abrt) return 1;
CHECK_WRITE(cpu_state.ea_seg, cpu_state.eaaddr, cpu_state.eaaddr + 1);
seteaw(temp);
CLOCK_CYCLES(timing_rr);
PREFETCH_RUN(timing_rr, 4, rmdat, 0,0,(cpu_mod == 3) ? 1:0,0, 1);
@@ -229,6 +232,7 @@ static int opMOV_l_imm_a16(uint32_t fetchdat)
fetch_ea_16(fetchdat);
ILLEGAL_ON((rmdat & 0x38) != 0);
temp = getlong(); if (cpu_state.abrt) return 1;
CHECK_WRITE(cpu_state.ea_seg, cpu_state.eaaddr, cpu_state.eaaddr + 3);
seteal(temp);
CLOCK_CYCLES(timing_rr);
PREFETCH_RUN(timing_rr, 6, rmdat, 0,0,0,(cpu_mod == 3) ? 1:0, 0);
@@ -240,6 +244,7 @@ static int opMOV_l_imm_a32(uint32_t fetchdat)
fetch_ea_32(fetchdat);
ILLEGAL_ON((rmdat & 0x38) != 0);
temp = getlong(); if (cpu_state.abrt) return 1;
CHECK_WRITE(cpu_state.ea_seg, cpu_state.eaaddr, cpu_state.eaaddr + 3);
seteal(temp);
CLOCK_CYCLES(timing_rr);
PREFETCH_RUN(timing_rr, 6, rmdat, 0,0,0,(cpu_mod == 3) ? 1:0, 1);