improve debug print to the log file which is printed in case of triple fault - tell VMX host/guest info

This commit is contained in:
Stanislav Shwartsman 2013-10-20 16:41:34 +00:00
parent 6f9400d4e8
commit d52adaa0ee

View File

@ -108,8 +108,13 @@ const char* cpu_state_string(unsigned state)
void BX_CPU_C::debug(bx_address offset)
{
BX_INFO(("CPU is in %s (%s)", cpu_mode_string(BX_CPU_THIS_PTR get_cpu_mode()),
cpu_state_string(BX_CPU_THIS_PTR activity_state)));
BX_INFO(("CPU is in %s (%s%s)", cpu_mode_string(BX_CPU_THIS_PTR get_cpu_mode()),
cpu_state_string(BX_CPU_THIS_PTR activity_state),
#if BX_SUPPORT_VMX
BX_CPU_THIS_PTR in_vmx_guest ? ", vmx guest" :
#endif
""
));
BX_INFO(("CS.mode = %u bit",
long64_mode() ? 64 : (BX_CPU_THIS_PTR sregs[BX_SEG_REG_CS].cache.u.segment.d_b ? 32 : 16)));
BX_INFO(("SS.mode = %u bit",