Fixed compilation error + x86-64 correctness fix

This commit is contained in:
Stanislav Shwartsman 2009-02-09 19:46:34 +00:00
parent a1a4574074
commit 6003f52704
3 changed files with 8 additions and 6 deletions

View File

@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
// $Id: cpu.h,v 1.569 2009-02-03 21:11:31 sshwarts Exp $
// $Id: cpu.h,v 1.570 2009-02-09 19:46:34 sshwarts Exp $
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001 MandrakeSoft S.A.
@ -3375,7 +3375,9 @@ public: // for now...
#endif
BX_SMF bx_address read_CR0(void);
#if BX_CPU_LEVEL > 3
BX_SMF bx_address read_CR4(void);
#endif
#if BX_SUPPORT_VMX
BX_SMF Bit32u VMread32(unsigned encoding);
BX_SMF void VMwrite32(unsigned encoding, Bit32u val_32);

View File

@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
// $Id: descriptor.h,v 1.27 2009-01-16 18:18:58 sshwarts Exp $
// $Id: descriptor.h,v 1.28 2009-02-09 19:46:34 sshwarts Exp $
/////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2007 Stanislav Shwartsman
@ -173,9 +173,7 @@ union {
#define IS_CODE_SEGMENT_CONFORMING(type) (((type) >> 2) & 0x1)
#define IS_DATA_SEGMENT_EXPAND_DOWN(type) (((type) >> 2) & 0x1)
#define IS_CODE_SEGMENT_READABLE(type) (((type) >> 1) & 0x1)
// data segment writeable bit is ignored when in 64-bit mode
#define IS_DATA_SEGMENT_WRITEABLE(type) (Is64BitMode() || (((type) >> 1) & 0x1))
#define IS_DATA_SEGMENT_WRITEABLE(type) (((type) >> 1) & 0x1)
#define IS_SEGMENT_ACCESSED(type) ((type) & 0x1)

View File

@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
// $Id: proc_ctrl.cc,v 1.284 2009-02-06 15:25:57 sshwarts Exp $
// $Id: proc_ctrl.cc,v 1.285 2009-02-09 19:46:34 sshwarts Exp $
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001 MandrakeSoft S.A.
@ -1266,6 +1266,7 @@ bx_address BX_CPU_C::read_CR0(void)
return cr0_val;
}
#if BX_CPU_LEVEL > 3
bx_address BX_CPU_C::read_CR4(void)
{
bx_address cr4_val = BX_CPU_THIS_PTR cr4.get32();
@ -1279,6 +1280,7 @@ bx_address BX_CPU_C::read_CR4(void)
return cr4_val;
}
#endif
bx_bool BX_CPP_AttrRegparmN(1) BX_CPU_C::SetCR0(bx_address val)
{