VirtualBox

Changeset 32133 in vbox


Ignore:
Timestamp:
Aug 31, 2010 12:06:50 PM (14 years ago)
Author:
vboxsync
Message:

vm.h/mac: alignment fixes.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/vm.h

    r32124 r32133  
    9595    /** Ring-0 Host Context VM Pointer. */
    9696    PVMR0                   pVMR0;
     97    /** Alignment padding. */
     98    RTR0PTR                 pvR0Padding;
    9799    /** Raw-mode Context VM Pointer. */
    98100    PVMRC                   pVMRC;
     
    112114    STAMPROFILEADV          aStatAdHoc[8];
    113115
    114 #if HC_ARCH_BITS == 32
    115116    /** Align the next bit on a 64-byte boundary and make sure it starts at the same
    116117     *  offset in both 64-bit and 32-bit builds.
     
    121122     *          following it (to grow into and align the struct size).
    122123     *   */
    123     uint8_t                 abAlignment1[HC_ARCH_BITS == 32 ? 20 : 0];
    124 #endif
     124    uint8_t                 abAlignment1[HC_ARCH_BITS == 32 ? 64 : 56];
    125125
    126126    /** CPUM part. */
     
    207207
    208208    /** Align the following members on page boundrary. */
    209     uint8_t                 abAlignment2[256];
     209    uint8_t                 abAlignment2[192];
    210210
    211211    /** PGM part. */
  • trunk/include/VBox/vm.mac

    r32124 r32133  
    117117    .pVMR3                  RTR3PTR_RES 1
    118118    .pVMR0                  RTR0PTR_RES 1
     119    .pvR0Padding            RTR0PTR_RES 1
    119120    .pVMRC                  RTRCPTR_RES 1
    120121    .idCpu                  resd 1
  • trunk/src/VBox/VMM/testcase/tstVMStructSize.cpp

    r31402 r32133  
    228228    CHECK_PADDING_VMCPU(64, iom);
    229229    CHECK_PADDING_VMCPU(64, dbgf);
     230    PRINT_OFFSET(VMCPU, abAlignment2);
     231    PRINT_OFFSET(VMCPU, pgm);
    230232    CHECK_PADDING_VMCPU(4096, pgm);
    231233#ifdef VBOX_WITH_STATISTICS
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette