VirtualBox

Changeset 89142 in vbox for trunk/src/VBox


Ignore:
Timestamp:
May 18, 2021 2:33:03 PM (4 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
144483
Message:

ValKit/bootsectors: Added a rough outline for a TSC timing test. bugref:10009

Location:
trunk/src/VBox/ValidationKit/bootsectors
Files:
1 added
1 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/bootsectors/Makefile.kmk

    r88839 r89142  
    383383#       $$(bs3-timers-1_0_OUTDIR)/bs3-timers-1-asm.o16
    384384
     385# Timing
     386MISCBINS += bs3-timing-1
     387bs3-timing-1_TEMPLATE = VBoxBS3KitImg
     388bs3-timing-1_INCS  = .
     389bs3-timing-1_DEFS  =  BS3_CMN_INSTANTIATE_FILE1=bs3-timing-1-template.c
     390bs3-timing-1_DEFS += BS3_MODE_INSTANTIATE_FILE1=bs3-timing-1-template.c
     391 ifeq ($(KBUILD_HOST),win)
     392bs3-timing-1_DEFS += HAVE_OMF_CONVERTER
     393 endif
     394bs3-timing-1_SOURCES = \
     395        bs3kit/bs3-first-rm.asm \
     396        bs3-timing-1.c \
     397        bs3-timing-1-32.c32
     398
    385399endif # VBOX_WITH_BS3KIT
    386400
  • trunk/src/VBox/ValidationKit/bootsectors/bs3-timing-1.c

    r89138 r89142  
    11/* $Id$ */
    22/** @file
    3  * BS3Kit - bs3-timers-1, 16-bit C code.
     3 * BS3Kit - bs3-timing-1, 16-bit C code.
    44 */
    55
     
    3636*   Internal Functions                                                                                                           *
    3737*********************************************************************************************************************************/
    38 FNBS3TESTDOMODE             bs3Timers1_Pit_100Hz_f16;
    39 FNBS3TESTDOMODE             bs3Timers1_Pit_1000Hz_f16;
    40 FNBS3TESTDOMODE             bs3Timers1_Pit_2000Hz_f16;
    41 FNBS3TESTDOMODE             bs3Timers1_Pit_4000Hz_f16;
     38BS3_DECL_CALLBACK(void)     bs3Timing1_Tsc_pe32();
    4239
    43 
    44 /*********************************************************************************************************************************
    45 *   Global Variables                                                                                                             *
    46 *********************************************************************************************************************************/
    47 static const BS3TESTMODEBYONEENTRY g_aModeByOneTests[] =
    48 {
    49     { "pit-100Hz",      bs3Timers1_Pit_100Hz_f16,  BS3TESTMODEBYONEENTRY_F_MINIMAL },
    50     { "pit-1000Hz",     bs3Timers1_Pit_1000Hz_f16, BS3TESTMODEBYONEENTRY_F_MINIMAL },
    51     { "pit-2000Hz",     bs3Timers1_Pit_2000Hz_f16, BS3TESTMODEBYONEENTRY_F_MINIMAL },
    52     { "pit-4000Hz",     bs3Timers1_Pit_4000Hz_f16, BS3TESTMODEBYONEENTRY_F_MINIMAL },
    53 };
    5440
    5541
     
    5743{
    5844    Bs3InitAll_rm();
    59     Bs3TestInit("bs3-timers-1");
     45    Bs3TestInit("bs3-timing-1");
    6046
    61     Bs3TestDoModesByOne_rm(g_aModeByOneTests, RT_ELEMENTS(g_aModeByOneTests), 0);
     47    /* Switch to PE32 and do the work from there, all the 64-bit integer
     48       handling should be a little more efficient in 32-bit mode. */
     49    Bs3SwitchTo32BitAndCallC_rm(bs3Timing1_Tsc_pe32, 0);
    6250
    6351    Bs3TestTerm();
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