VirtualBox

Changeset 30843 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Jul 14, 2010 2:29:41 PM (15 years ago)
Author:
vboxsync
Message:

Profile map/unmap operations

Location:
trunk/src/VBox/VMM
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/PGM.cpp

    r30840 r30843  
    16451645    PGM_REG_COUNTER(&pPGM->StatRZChunkR3MapTlbHits,           "/PGM/ChunkR3Map/TlbHitsRZ",          "TLB hits.");
    16461646    PGM_REG_COUNTER(&pPGM->StatRZChunkR3MapTlbMisses,         "/PGM/ChunkR3Map/TlbMissesRZ",        "TLB misses.");
     1647    PGM_REG_PROFILE(&pPGM->StatChunkAging,                    "/PGM/ChunkR3Map/Map/Aging",          "Chunk aging profiling.");
     1648    PGM_REG_PROFILE(&pPGM->StatChunkFindCandidate,            "/PGM/ChunkR3Map/Map/Find",           "Chunk unmap find profiling.");
     1649    PGM_REG_PROFILE(&pPGM->StatChunkUnmap,                    "/PGM/ChunkR3Map/Map/Unmap",          "Chunk unmap of address space profiling.");
     1650    PGM_REG_PROFILE(&pPGM->StatChunkMap,                      "/PGM/ChunkR3Map/Map/Map",            "Chunk map of address space profiling.");
     1651
    16471652    PGM_REG_COUNTER(&pPGM->StatRZPageMapTlbHits,              "/PGM/RZ/Page/MapTlbHits",            "TLB hits.");
    16481653    PGM_REG_COUNTER(&pPGM->StatRZPageMapTlbMisses,            "/PGM/RZ/Page/MapTlbMisses",          "TLB misses.");
  • trunk/src/VBox/VMM/PGMInternal.h

    r30842 r30843  
    28922892    /** pgmPhysIsValidLargePage profiling - RZ*/
    28932893    STAMPROFILE                 StatRZIsValidLargePage;
     2894
     2895    STAMPROFILE                 StatChunkAging;
     2896    STAMPROFILE                 StatChunkFindCandidate;
     2897    STAMPROFILE                 StatChunkUnmap;
     2898    STAMPROFILE                 StatChunkMap;
    28942899#endif
    28952900} PGM;
  • trunk/src/VBox/VMM/PGMPhys.cpp

    r30842 r30843  
    33153315     */
    33163316    if (pVM->pgm.s.ChunkR3Map.AgeingCountdown-- == 0)
     3317    {
     3318        STAM_PROFILE_START(&pVM->pgm.s.StatChunkAging, a);
    33173319        PGMR3PhysChunkAgeing(pVM);
     3320        STAM_PROFILE_STOP(&pVM->pgm.s.StatChunkAging, a);
     3321    }
    33183322
    33193323    /*
    33203324     * Enumerate the age tree starting with the left most node.
    33213325     */
     3326    STAM_PROFILE_START(&pVM->pgm.s.StatChunkFindCandidate, a);
    33223327    PGMR3PHYSCHUNKUNMAPCB Args;
    33233328    Args.pVM      = pVM;
     
    33273332    Assert(Args.pChunk);
    33283333    if (Args.pChunk)
     3334    {
     3335        STAM_PROFILE_STOP(&pVM->pgm.s.StatChunkFindCandidate, a);
    33293336        return Args.pChunk->Core.Key;
    3330 
     3337    }
     3338
     3339    STAM_PROFILE_STOP(&pVM->pgm.s.StatChunkFindCandidate, a);
    33313340    return INT32_MAX;
    33323341}
     
    33673376        if (Req.idChunkUnmap != INT32_MAX)
    33683377        {
     3378            STAM_PROFILE_START(&pVM->pgm.s.StatChunkUnmap, a);
    33693379            rc = VMMR3CallR0(pVM, VMMR0_DO_GMM_MAP_UNMAP_CHUNK, 0, &Req.Hdr);
     3380            STAM_PROFILE_START(&pVM->pgm.s.StatChunkUnmap, a);
    33703381            if (RT_SUCCESS(rc))
    33713382            {
     
    34713482
    34723483    /* Must be callable from any thread, so can't use VMMR3CallR0. */
     3484    STAM_PROFILE_START(&pVM->pgm.s.StatChunkMap, a);
    34733485    rc = SUPR3CallVMMR0Ex(pVM->pVMR0, NIL_VMCPUID, VMMR0_DO_GMM_MAP_UNMAP_CHUNK, 0, &Req.Hdr);
     3486    STAM_PROFILE_STOP(&pVM->pgm.s.StatChunkMap, a);
    34743487    if (RT_SUCCESS(rc))
    34753488    {
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