fixed code duplication related to EXT field

This commit is contained in:
Stanislav Shwartsman 2012-09-29 09:31:34 +00:00
parent 2d4f9009cd
commit e397a86ce0
6 changed files with 2 additions and 7 deletions

View File

@ -80,7 +80,6 @@ void BX_CPU_C::cpu_loop(void)
// mirrors similar code below, after the interrupt() call.
BX_CPU_THIS_PTR prev_rip = RIP; // commit new EIP
BX_CPU_THIS_PTR speculative_rsp = 0;
BX_CPU_THIS_PTR EXT = 0;
while (1) {

View File

@ -128,7 +128,6 @@ void BX_CPU_C::InterruptAcknowledge(void)
interrupt(vector, BX_EXTERNAL_INTERRUPT, 0, 0);
BX_CPU_THIS_PTR prev_rip = RIP; // commit new RIP
BX_CPU_THIS_PTR EXT = 0;
}
#if BX_SUPPORT_SVM
@ -147,7 +146,6 @@ void BX_CPU_C::VirtualInterruptAcknowledge(void)
interrupt(vector, BX_EXTERNAL_INTERRUPT, 0, 0);
BX_CPU_THIS_PTR prev_rip = RIP; // commit new RIP
BX_CPU_THIS_PTR EXT = 0;
}
#endif

View File

@ -762,6 +762,8 @@ void BX_CPU_C::interrupt(Bit8u vector, unsigned type, bx_bool push_error, Bit16u
#if BX_SUPPORT_VMX || BX_SUPPORT_SVM
BX_CPU_THIS_PTR in_event = 0;
#endif
BX_CPU_THIS_PTR EXT = 0;
}
/* Exception classes. These are used as indexes into the 'is_exception_OK'

View File

@ -81,8 +81,6 @@ BX_INSF_TYPE BX_CPP_AttrRegparmN(1) BX_CPU_C::INT1(bxInstruction_c *i)
// interrupt is not RSP safe
interrupt(1, BX_PRIVILEGED_SOFTWARE_INTERRUPT, 0, 0);
BX_CPU_THIS_PTR EXT = 0;
BX_INSTR_FAR_BRANCH(BX_CPU_ID, BX_INSTR_IS_INT,
BX_CPU_THIS_PTR sregs[BX_SEG_REG_CS].selector.value,
EIP);

View File

@ -695,7 +695,6 @@ bx_bool BX_CPU_C::SvmInjectEvents(void)
interrupt(vector, type, push_error, error_code);
BX_CPU_THIS_PTR errorno = 0; // injection success
BX_CPU_THIS_PTR EXT = 0;
return 1;
}

View File

@ -1711,7 +1711,6 @@ void BX_CPU_C::VMenterInjectEvents(void)
interrupt(vector, type, push_error, error_code);
BX_CPU_THIS_PTR errorno = 0; // injection success
BX_CPU_THIS_PTR EXT = 0;
}
Bit32u BX_CPU_C::LoadMSRs(Bit32u msr_cnt, bx_phy_address pAddr)