Obtaining a Performance Profile for a Display Driver
Once you have built your platform in How to Profile and Optimize a Display Driver and downloaded it onto your device, you can start to gather data about the behavior and performance of your display driver. For more information, see Monte Carlo Profiling and Display Driver Performance Profiling.
To obtain a Monte Carlo profile for the display driver
In the Output window of the Platform Builder IDE, choose the Debug tab to monitor the profiling output as it is generated.
On the Windows CE-based device, press the F9 key to begin profiling. The debug output includes the following message:
Kernel Profiler: Gathering MonteCarlo data in buffered mode ProfileStart() : Allocated 13960 kB for Profiler Buffer (0x48000000) Starting profile timer at 200 uS rate
In the Target Control window of the Platform Builder IDE, enter the following command to launch ProfApp.exe:
s profapp
ProfApp.exe randomly fills the device's display with a blue and green checkerboard pattern when it runs.
Note Try to use your device in a consistent manner while you are gathering profiling data because the profiling tools pick up all the calls on your system. This includes driver and system calls to repaint the mouse pointer, menu activity, dialog boxes, and all the other activity on your system, as well as the application you are trying to profile, DispPerf.exe. Erratic and unpredictable activities produce erratic and unpredictable results and complicate your later analysis.
When ProfApp.exe is finished, it writes the following message in the debug output:
ProfApp: Took 34297 ms to perform blts.
On the device, press the F12 key to stop profiling. The results are written to the debug output and should look similar to the following output:
Kernel Profiler: Looking up symbols for 503297 hits. . (Additional lines omitted for clarity.) . Total samples recorded = 503297 Module Hits Percent ------------ ---------- ------- nk.exe 332367 66.0 . (Additional lines omitted for clarity.) . Hits Percent Address Module Routine ---------- ------- -------- ------------:--------------------- 328544 65.2 802351c2 nk.exe :_IDLE_STATE 101277 20.1 03db634d ddi_flat.dll:?EmulatedBlt_Internal 64291 12.7 03db7c7f ddi_flat.dll:?MaskedSrcToMaskedDst
For a more complete listing of the results, see Display Device Performance Profile Analysis.
While you were running the Monte Carlo profiler, the instrumented calls in the display driver were recording use and performance data. The DispPerf.exe application reads this data and provides a report of profiling metrics for each type of raster operation (ROP) performed during the profiling period.
To obtain profiling results from DispPerf.exe
From the Start menu on your device, choose Programs and then choose Command Prompt. A command prompt opens on your device.
Enter the following command:
dispperf /x > \Release\DispPerf_Results.csv
This command writes the profiling results to a comma-separated variable (.csv) file in your platform's release directory on your Platform Builder workstation.
On your Platform Builder workstation, open the file %_WINCEROOT%\PUBLIC\<Platform Name>\RelDir\CEPC_X86Release\DispPerf_Results.csv with a spreadsheet application to review the profiling results for your display driver. For a more complete listing of the results, see Display Device Performance Profile Analysis.
See Also
How to Profile and Optimize a Display Driver | Controlling Profiling Using the Device Keyboard when Running the Profile-Enabled OS Image
Last updated on Tuesday, May 18, 2004
© 1992-2003 Microsoft Corporation. All rights reserved.