VirtualBox

Changeset 92258 in vbox for trunk/include


Ignore:
Timestamp:
Nov 8, 2021 9:18:20 AM (3 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
148098
Message:

IPRT,VMMDev,ValKit: Some new test units. bugref:10093

Location:
trunk/include
Files:
2 edited

Legend:

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

    r90503 r92258  
    142142
    143143/** @name Value units
     144 * @note Same as RTTESTUNIT, see rules here for adding new units.
    144145 * @{ */
    145146#define VMMDEV_TESTING_UNIT_PCT                 UINT8_C(0x01)   /**< Percentage. */
     
    170171#define VMMDEV_TESTING_UNIT_INSTRS_PER_SEC      UINT8_C(0x1a)   /**< Instructions per second. */
    171172#define VMMDEV_TESTING_UNIT_NONE                UINT8_C(0x1b)   /**< No unit. */
     173#define VMMDEV_TESTING_UNIT_PP1K                UINT8_C(0x1c)   /**< Parts per thousand (10^-3). */
     174#define VMMDEV_TESTING_UNIT_PP10K               UINT8_C(0x1d)   /**< Parts per ten thousand (10^-4). */
     175#define VMMDEV_TESTING_UNIT_PPM                 UINT8_C(0x1e)   /**< Parts per million (10^-6). */
     176#define VMMDEV_TESTING_UNIT_PPB                 UINT8_C(0x1f)   /**< Parts per billion (10^-9). */
     177#define VMMDEV_TESTING_UNIT_TICKS               UINT8_C(0x20)   /**< CPU ticks. */
     178#define VMMDEV_TESTING_UNIT_TICKS_PER_CALL      UINT8_C(0x21)   /**< CPU ticks per call. */
     179#define VMMDEV_TESTING_UNIT_TICKS_PER_OCCURENCE UINT8_C(0x22)   /**< CPU ticks per occurence. */
     180#define VMMDEV_TESTING_UNIT_PAGES               UINT8_C(0x23)   /**< Page count. */
     181#define VMMDEV_TESTING_UNIT_PAGES_PER_SEC       UINT8_C(0x24)   /**< Pages per second. */
     182#define VMMDEV_TESTING_UNIT_TICKS_PER_PAGE      UINT8_C(0x25)   /**< CPU ticks per page. */
     183#define VMMDEV_TESTING_UNIT_NS_PER_PAGE         UINT8_C(0x26)   /**< Nanoseconds per page. */
    172184/** @}  */
    173185
  • trunk/include/iprt/test.h

    r88311 r92258  
    470470 *          contant values.
    471471 * @remarks When adding a new item:
    472  *              - Always add at the end of the list - do NOT group it.
     472 *              - Always add at the end of the list.
    473473 *              - Add it to rtTestUnitName in r3/test.cpp.
    474  *              - include/VBox/VMMDevTesting.h (VMMDEV_TESTING_UNIT_XXX).
     474 *              - Add it as VMMDEV_TESTING_UNIT_ in include/VBox/VMMDevTesting.h.
    475475 *              - Add it to g_aszBs2TestUnitNames in
    476  *                TestSuite/bootsectors/bootsector2-common-routines.mac.
    477  *
     476 *                ValidationKit/bootsectors/bootsector2-common-routines.mac.
     477 *              - Add it to g_aszBs3TestUnitNames in bs3kit/bs3-cmn-TestData.c.
    478478 */
    479479typedef enum RTTESTUNIT
     
    513513    RTTESTUNIT_PPM,                             /**< Parts per million (10^-6). */
    514514    RTTESTUNIT_PPB,                             /**< Parts per billion (10^-9). */
     515    RTTESTUNIT_TICKS,                           /**< CPU ticks. */
     516    RTTESTUNIT_TICKS_PER_CALL,                  /**< CPU ticks per call. */
     517    RTTESTUNIT_TICKS_PER_OCCURENCE,             /**< CPU ticks per occurence. */
     518    RTTESTUNIT_PAGES,                           /**< Page count. */
     519    RTTESTUNIT_PAGES_PER_SEC,                   /**< Pages per second. */
     520    RTTESTUNIT_TICKS_PER_PAGE,                  /**< CPU ticks per page. */
     521    RTTESTUNIT_NS_PER_PAGE,                     /**< Nanoseconds per page. */
    515522
    516523    /** The end of valid units. */
    517524    RTTESTUNIT_END
    518525} RTTESTUNIT;
    519 AssertCompile(RTTESTUNIT_INSTRS == 0x19);
    520 AssertCompile(RTTESTUNIT_NONE   == 0x1b);
     526AssertCompile(RTTESTUNIT_INSTRS      == 0x19);
     527AssertCompile(RTTESTUNIT_NONE        == 0x1b);
     528AssertCompile(RTTESTUNIT_NS_PER_PAGE == 0x26);
    521529
    522530/**
Note: See TracChangeset for help on using the changeset viewer.

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