Got rid of get_bit{1,3,5,15} accessors to EFLAGS. They were

only used by the debug functions, and those can get the
entire eflags value in one shot now.
This commit is contained in:
Kevin Lawton 2002-09-13 05:03:37 +00:00
parent 8f9c3c582d
commit bbb20f5d49
2 changed files with 3 additions and 34 deletions

View File

@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
// $Id: cpu.h,v 1.47 2002-09-13 01:09:10 kevinlawton Exp $
// $Id: cpu.h,v 1.48 2002-09-13 05:03:37 kevinlawton Exp $
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001 MandrakeSoft S.A.
@ -360,11 +360,6 @@ typedef struct {
*/
Bit32u val32; // Raw 32-bit value in x86 bit position. Used to store
// some eflags which are not cached in separate fields.
BX_CPP_INLINE Boolean get_bit1() { return 1; }
BX_CPP_INLINE Boolean get_bit3() { return 0; }
BX_CPP_INLINE Boolean get_bit5() { return 0; }
BX_CPP_INLINE Boolean get_bit15() { return 0; }
} bx_flags_reg_t;
// accessors for all eflags in bx_flags_reg_t

View File

@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
// $Id: debugstuff.cc,v 1.15 2002-09-13 00:15:23 kevinlawton Exp $
// $Id: debugstuff.cc,v 1.16 2002-09-13 05:03:37 kevinlawton Exp $
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001 MandrakeSoft S.A.
@ -299,33 +299,7 @@ BX_CPU_C::dbg_query_pending(void)
Bit32u
BX_CPU_C::dbg_get_eflags(void)
{
Bit32u val32;
val32 =
(BX_CPU_THIS_PTR get_CF()) |
(BX_CPU_THIS_PTR eflags.get_bit1 () << 1) |
((BX_CPU_THIS_PTR get_PF()) << 2) |
(BX_CPU_THIS_PTR eflags.get_bit3 () << 3) |
((BX_CPU_THIS_PTR get_AF()>0) << 4) |
(BX_CPU_THIS_PTR eflags.get_bit5 () << 5) |
((BX_CPU_THIS_PTR get_ZF()>0) << 6) |
((BX_CPU_THIS_PTR get_SF()>0) << 7) |
(BX_CPU_THIS_PTR get_TF () << 8) |
(BX_CPU_THIS_PTR get_IF () << 9) |
(BX_CPU_THIS_PTR get_DF () << 10) |
((BX_CPU_THIS_PTR get_OF()>0) << 11) |
(BX_CPU_THIS_PTR get_IOPL () << 12) |
(BX_CPU_THIS_PTR get_NT () << 14) |
(BX_CPU_THIS_PTR eflags.get_bit15 () << 15) |
(BX_CPU_THIS_PTR get_RF () << 16) |
(BX_CPU_THIS_PTR get_VM () << 17);
#if BX_CPU_LEVEL >= 4
val32 |= (BX_CPU_THIS_PTR get_AC () << 18);
//val32 |= (BX_CPU_THIS_PTR eflags.get_VIF () << 19);
//val32 |= (BX_CPU_THIS_PTR eflags.get_VIP () << 20);
val32 |= (BX_CPU_THIS_PTR get_ID () << 21);
#endif
return(val32);
return(BX_CPU_THIS_PTR eflags.val32);
}