tstVMStructSize.cpp revision 389da1638f530ddb14b3cc1c05f7af0badc3f0d5
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync/* $Id$ */
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync/** @file
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * tstVMStructSize - testcase for check structure sizes/alignment
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync * and to verify that HC and GC uses the same
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync * representation of the structures.
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync */
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync/*
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync * Copyright (C) 2006-2007 Oracle Corporation
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync *
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * available from http://www.virtualbox.org. This file is free software;
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * you can redistribute it and/or modify it under the terms of the GNU
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * General Public License (GPL) as published by the Free Software
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync */
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync/*******************************************************************************
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync* Header Files *
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync*******************************************************************************/
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync#include <VBox/vmm/cfgm.h>
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync#include <VBox/vmm/cpum.h>
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync#include <VBox/vmm/mm.h>
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync#include <VBox/vmm/pgm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/selm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/trpm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/vmm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/stam.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "PDMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/pdm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "CFGMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "CPUMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "MMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "PGMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "SELMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "TRPMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "TMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "IOMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "REMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "SSMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "HWACCMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "PATMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "VMMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "DBGFInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "STAMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "VMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "CSAMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "EMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "IEMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "REMInternal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "../VMMR0/GMMR0Internal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "../VMMR0/GVMMR0Internal.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/vm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/vmm/uvm.h>
0493c79a1867f7760af6bc330c8c42a09da852abvboxsync#include <VBox/vmm/gvm.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/param.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <VBox/x86.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include "tstHelp.h"
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#include <stdio.h>
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsyncint main()
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync{
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync int rc = 0;
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("tstVMStructSize: TESTING\n");
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("info: struct VM: %d bytes\n", (int)sizeof(VM));
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_VM(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING(VM, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync VM *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: VM::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_VMCPU(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING(VMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync VMCPU *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: VMCPU::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_CPUMCTXCORE(member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (RT_OFFSETOF(CPUMCTX, member) - RT_OFFSETOF(CPUMCTX, edi) != RT_OFFSETOF(CPUMCTXCORE, member)) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("error! CPUMCTX/CORE:: %s!\n", #member); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync rc++; \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_UVM(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING(UVM, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(UVM, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync UVM *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: UVM::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_UVMCPU(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING(UVMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(UVMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync UVMCPU *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: UVMCPU::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_GVM(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING(GVM, member, align); \
8bed792bc65abd39393889351f22263ce6c289bfvboxsync CHECK_MEMBER_ALIGNMENT(GVM, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync GVM *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: GVM::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define CHECK_PADDING_GVMCPU(align, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync { \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING(GVMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(GVMCPU, member, align); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync GVMCPU *p = NULL; NOREF(p); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if (sizeof(p->member.padding) >= (ssize_t)sizeof(p->member.s) + 128 + sizeof(p->member.s) / 20) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("warning: GVMCPU::%-8s: padding=%-5d s=%-5d -> %-4d suggest=%-5u\n", \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync #member, (int)sizeof(p->member.padding), (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)sizeof(p->member.padding) - (int)sizeof(p->member.s), \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync (int)RT_ALIGN_Z(sizeof(p->member.s), (align))); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#define PRINT_OFFSET(strct, member) \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync do \
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync { \
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync printf("info: %s::%s offset %#x (%d) sizeof %d\n", #strct, #member, (int)RT_OFFSETOF(strct, member), (int)RT_OFFSETOF(strct, member), (int)RT_SIZEOFMEMB(strct, member)); \
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync } while (0)
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(uint128_t, 128/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(int128_t, 128/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(uint64_t, 64/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(int64_t, 64/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(uint32_t, 32/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(int32_t, 32/8);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(uint16_t, 16/8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(int16_t, 16/8);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(uint8_t, 8/8);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(int8_t, 8/8);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(X86DESC, 8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86DESC64, 16);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(VBOXIDTE, 8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(VBOXIDTR, 10);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(VBOXGDTR, 10);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(VBOXTSS, 136);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(X86FXSTATE, 512);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(RTUUID, 16);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PTE, 4);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PD, PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PDE, 4);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PT, PAGE_SIZE);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(X86PTEPAE, 8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PTPAE, PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PDEPAE, 8);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(X86PDPAE, PAGE_SIZE);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_SIZE(X86PDPE, 8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PDPT, PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PML4E, 8);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_SIZE(X86PML4, PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VM, cpum);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, cpum);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, vmm);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VM(64, pgm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, hwaccm);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VM(64, trpm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, selm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, mm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, pdm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, iom);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, patm);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VM(64, csam);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, em);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync /*CHECK_PADDING_VM(64, iem);*/
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VM(64, tm);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VM(64, dbgf);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, ssm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(64, rem);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(8, vm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VM(8, cfgm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VMCPU, cpum);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, cpum);
a0f8619bc2bbe3614578c21b5b50a88d2841e7aavboxsync CHECK_PADDING_VMCPU(64, hwaccm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, em);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, iem);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, trpm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, tm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, vmm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, pdm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, iom);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(64, dbgf);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#if 0
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VMCPU, abAlignment2);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#endif
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VMCPU, pgm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_PADDING_VMCPU(4096, pgm);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#ifdef VBOX_WITH_STATISTICS
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VMCPU, pgm.s.pStatTrap0eAttributionRC);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#endif
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, selm.s.Tss, 16);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VM, selm.s.Tss);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PVM pVM = NULL; NOREF(pVM);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if ((RT_OFFSETOF(VM, selm.s.Tss) & PAGE_OFFSET_MASK) > PAGE_SIZE - sizeof(pVM->selm.s.Tss))
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync {
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("error! SELM:Tss is crossing a page!\n");
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync rc++;
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync }
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync PRINT_OFFSET(VM, selm.s.TssTrap08);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync if ((RT_OFFSETOF(VM, selm.s.TssTrap08) & PAGE_OFFSET_MASK) > PAGE_SIZE - sizeof(pVM->selm.s.TssTrap08))
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync {
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync printf("error! SELM:TssTrap08 is crossing a page!\n");
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync rc++;
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync }
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, trpm.s.aIdt, 16);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[0], PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[1], PAGE_SIZE);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[0].cpum.s.Host, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[0].cpum.s.Guest, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[1].cpum.s.Host, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[1].cpum.s.Guest, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[0].cpum.s.Hyper, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, aCpus[1].cpum.s.Hyper, 64);
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync#ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI
632b4638bd18092c6b8edb4e1028c9be112f5076vboxsync CHECK_MEMBER_ALIGNMENT(VM, cpum.s.pvApicBase, 8);
#endif
CHECK_MEMBER_ALIGNMENT(VM, cpum.s.GuestEntry, 64);
CHECK_MEMBER_ALIGNMENT(VMCPU, vmm.s.u64CallRing3Arg, 8);
#if defined(RT_OS_WINDOWS) && defined(RT_ARCH_AMD64)
CHECK_MEMBER_ALIGNMENT(VMCPU, vmm.s.CallRing3JmpBufR0, 16);
CHECK_MEMBER_ALIGNMENT(VMCPU, vmm.s.CallRing3JmpBufR0.xmm6, 16);
#endif
CHECK_MEMBER_ALIGNMENT(VM, vmm.s.u64LastYield, 8);
CHECK_MEMBER_ALIGNMENT(VM, vmm.s.StatRunRC, 8);
CHECK_MEMBER_ALIGNMENT(VM, StatTotalQemuToGC, 8);
CHECK_MEMBER_ALIGNMENT(VM, rem.s.uPendingExcptCR2, 8);
CHECK_MEMBER_ALIGNMENT(VM, rem.s.StatsInQEMU, 8);
CHECK_MEMBER_ALIGNMENT(VM, rem.s.Env, 64);
/* the VMCPUs are page aligned TLB hit reasons. */
CHECK_MEMBER_ALIGNMENT(VM, aCpus, 4096);
CHECK_SIZE_ALIGNMENT(VMCPU, 4096);
/* cpumctx */
CHECK_MEMBER_ALIGNMENT(CPUMCTX, fpu, 32);
CHECK_MEMBER_ALIGNMENT(CPUMCTX, edi, 32);
CHECK_MEMBER_ALIGNMENT(CPUMCTX, idtr, 4);
CHECK_MEMBER_ALIGNMENT(CPUMCTX, SysEnter, 8);
CHECK_CPUMCTXCORE(eax);
CHECK_CPUMCTXCORE(ebx);
CHECK_CPUMCTXCORE(ecx);
CHECK_CPUMCTXCORE(edx);
CHECK_CPUMCTXCORE(ebp);
CHECK_CPUMCTXCORE(esp);
CHECK_CPUMCTXCORE(edi);
CHECK_CPUMCTXCORE(esi);
CHECK_CPUMCTXCORE(eip);
CHECK_CPUMCTXCORE(eflags);
CHECK_CPUMCTXCORE(cs);
CHECK_CPUMCTXCORE(ds);
CHECK_CPUMCTXCORE(es);
CHECK_CPUMCTXCORE(fs);
CHECK_CPUMCTXCORE(gs);
CHECK_CPUMCTXCORE(ss);
CHECK_CPUMCTXCORE(r8);
CHECK_CPUMCTXCORE(r9);
CHECK_CPUMCTXCORE(r10);
CHECK_CPUMCTXCORE(r11);
CHECK_CPUMCTXCORE(r12);
CHECK_CPUMCTXCORE(r13);
CHECK_CPUMCTXCORE(r14);
CHECK_CPUMCTXCORE(r15);
CHECK_CPUMCTXCORE(esHid);
CHECK_CPUMCTXCORE(csHid);
CHECK_CPUMCTXCORE(ssHid);
CHECK_CPUMCTXCORE(dsHid);
CHECK_CPUMCTXCORE(fsHid);
CHECK_CPUMCTXCORE(gsHid);
#if HC_ARCH_BITS == 32
/* CPUMHOSTCTX - lss pair */
if (RT_OFFSETOF(CPUMHOSTCTX, esp) + 4 != RT_OFFSETOF(CPUMHOSTCTX, ss))
{
printf("error! CPUMHOSTCTX lss has been split up!\n");
rc++;
}
#endif
CHECK_SIZE_ALIGNMENT(CPUMCTX, 64);
CHECK_SIZE_ALIGNMENT(CPUMHOSTCTX, 64);
CHECK_SIZE_ALIGNMENT(CPUMCTXMSR, 64);
/* pdm */
CHECK_MEMBER_ALIGNMENT(PDMDEVINS, achInstanceData, 64);
CHECK_PADDING(PDMDEVINS, Internal, 1);
CHECK_MEMBER_ALIGNMENT(PDMUSBINS, achInstanceData, 16);
CHECK_PADDING(PDMUSBINS, Internal, 1);
CHECK_MEMBER_ALIGNMENT(PDMDRVINS, achInstanceData, 16);
CHECK_PADDING(PDMDRVINS, Internal, 1);
CHECK_PADDING2(PDMCRITSECT);
/* pgm */
#if defined(VBOX_WITH_2X_4GB_ADDR_SPACE) || defined(VBOX_WITH_RAW_MODE)
CHECK_MEMBER_ALIGNMENT(PGMCPU, AutoSet, 8);
#endif
CHECK_MEMBER_ALIGNMENT(PGMCPU, GCPhysCR3, sizeof(RTGCPHYS));
CHECK_MEMBER_ALIGNMENT(PGMCPU, aGCPhysGstPaePDs, sizeof(RTGCPHYS));
CHECK_MEMBER_ALIGNMENT(PGMCPU, DisState, 8);
CHECK_MEMBER_ALIGNMENT(PGMCPU, cPoolAccessHandler, 8);
CHECK_MEMBER_ALIGNMENT(PGMPOOLPAGE, idx, sizeof(uint16_t));
CHECK_MEMBER_ALIGNMENT(PGMPOOLPAGE, pvPageR3, sizeof(RTHCPTR));
CHECK_MEMBER_ALIGNMENT(PGMPOOLPAGE, GCPhys, sizeof(RTGCPHYS));
CHECK_SIZE(PGMPAGE, 16);
CHECK_MEMBER_ALIGNMENT(PGMRAMRANGE, aPages, 16);
CHECK_MEMBER_ALIGNMENT(PGMMMIO2RANGE, RamRange, 16);
/* rem */
CHECK_MEMBER_ALIGNMENT(REM, aGCPtrInvalidatedPages, 8);
CHECK_PADDING3(REMHANDLERNOTIFICATION, u.PhysicalRegister, u.padding);
CHECK_PADDING3(REMHANDLERNOTIFICATION, u.PhysicalDeregister, u.padding);
CHECK_PADDING3(REMHANDLERNOTIFICATION, u.PhysicalModify, u.padding);
CHECK_SIZE_ALIGNMENT(REMHANDLERNOTIFICATION, 8);
CHECK_MEMBER_ALIGNMENT(REMHANDLERNOTIFICATION, u.PhysicalDeregister.GCPhys, 8);
/* TM */
CHECK_MEMBER_ALIGNMENT(TM, TimerCritSect, sizeof(uintptr_t));
CHECK_MEMBER_ALIGNMENT(TM, VirtualSyncLock, sizeof(uintptr_t));
/* misc */
CHECK_PADDING3(EMCPU, u.FatalLongJump, u.achPaddingFatalLongJump);
CHECK_SIZE_ALIGNMENT(VMMR0JMPBUF, 8);
CHECK_SIZE_ALIGNMENT(PATCHINFO, 8);
#if 0
PRINT_OFFSET(VM, fForcedActions);
PRINT_OFFSET(VM, StatQemuToGC);
PRINT_OFFSET(VM, StatGCToQemu);
#endif
CHECK_MEMBER_ALIGNMENT(IOM, EmtLock, sizeof(uintptr_t));
CHECK_MEMBER_ALIGNMENT(EM, CritSectREM, sizeof(uintptr_t));
CHECK_MEMBER_ALIGNMENT(PGM, CritSect, sizeof(uintptr_t));
CHECK_MEMBER_ALIGNMENT(PDM, CritSect, sizeof(uintptr_t));
CHECK_MEMBER_ALIGNMENT(MMHYPERHEAP, Lock, sizeof(uintptr_t));
/* hwaccm - 32-bit gcc won't align uint64_t naturally, so check. */
CHECK_MEMBER_ALIGNMENT(HWACCM, u64RegisterMask, 8);
CHECK_MEMBER_ALIGNMENT(HWACCM, vmx.hostCR4, 8);
CHECK_MEMBER_ALIGNMENT(HWACCM, vmx.msr.feature_ctrl, 8);
CHECK_MEMBER_ALIGNMENT(HWACCM, StatTPRPatchSuccess, 8);
CHECK_MEMBER_ALIGNMENT(HWACCMCPU, StatEntry, 8);
CHECK_MEMBER_ALIGNMENT(HWACCMCPU, vmx.pVMCSPhys, sizeof(RTHCPHYS));
CHECK_MEMBER_ALIGNMENT(HWACCMCPU, vmx.proc_ctls, 8);
CHECK_MEMBER_ALIGNMENT(HWACCMCPU, Event.intInfo, 8);
/* The various disassembler state members. */
CHECK_PADDING3(EMCPU, DisState, abDisStatePadding);
CHECK_PADDING3(HWACCMCPU, DisState, abDisStatePadding);
CHECK_PADDING3(IOMCPU, DisState, abDisStatePadding);
CHECK_PADDING3(PGMCPU, DisState, abDisStatePadding);
/* Make sure the set is large enough and has the correct size. */
CHECK_SIZE(VMCPUSET, 32);
if (sizeof(VMCPUSET) * 8 < VMM_MAX_CPU_COUNT)
{
printf("error! VMCPUSET is too small for VMM_MAX_CPU_COUNT=%u!\n", VMM_MAX_CPU_COUNT);
rc++;
}
printf("info: struct UVM: %d bytes\n", (int)sizeof(UVM));
CHECK_PADDING_UVM(32, vm);
CHECK_PADDING_UVM(32, mm);
CHECK_PADDING_UVM(32, pdm);
CHECK_PADDING_UVM(32, stam);
printf("info: struct UVMCPU: %d bytes\n", (int)sizeof(UVMCPU));
CHECK_PADDING_UVMCPU(32, vm);
#ifdef VBOX_WITH_RAW_MODE
/*
* Compare HC and RC.
*/
printf("tstVMStructSize: Comparing HC and RC...\n");
# include "tstVMStructRC.h"
#endif /* VBOX_WITH_RAW_MODE */
CHECK_PADDING_GVM(4, gvmm);
CHECK_PADDING_GVM(4, gmm);
CHECK_PADDING_GVMCPU(4, gvmm);
/*
* Check that the optimized access macros for PGMPAGE works correctly.
*/
PGMPAGE Page;
PGM_PAGE_CLEAR(&Page);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_NONE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == false);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == false);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == false);
PGM_PAGE_SET_HNDL_PHYS_STATE(&Page, PGM_PAGE_HNDL_PHYS_STATE_ALL);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_ALL);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == true);
PGM_PAGE_SET_HNDL_PHYS_STATE(&Page, PGM_PAGE_HNDL_PHYS_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == false);
PGM_PAGE_CLEAR(&Page);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_ALL);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_ALL);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == true);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == false);
PGM_PAGE_CLEAR(&Page);
PGM_PAGE_SET_HNDL_PHYS_STATE(&Page, PGM_PAGE_HNDL_PHYS_STATE_ALL);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_ALL);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == true);
PGM_PAGE_SET_HNDL_PHYS_STATE(&Page, PGM_PAGE_HNDL_PHYS_STATE_WRITE);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_ALL);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_ALL);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == true);
PGM_PAGE_SET_HNDL_PHYS_STATE(&Page, PGM_PAGE_HNDL_PHYS_STATE_WRITE);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == false);
PGM_PAGE_SET_HNDL_VIRT_STATE(&Page, PGM_PAGE_HNDL_VIRT_STATE_NONE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_PHYS_STATE(&Page) == PGM_PAGE_HNDL_PHYS_STATE_WRITE);
CHECK_EXPR(PGM_PAGE_GET_HNDL_VIRT_STATE(&Page) == PGM_PAGE_HNDL_VIRT_STATE_NONE);
CHECK_EXPR(PGM_PAGE_HAS_ANY_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_HANDLERS(&Page) == true);
CHECK_EXPR(PGM_PAGE_HAS_ACTIVE_ALL_HANDLERS(&Page) == false);
/*
* Report result.
*/
if (rc)
printf("tstVMStructSize: FAILURE - %d errors\n", rc);
else
printf("tstVMStructSize: SUCCESS\n");
return rc;
}