There are two profiling methods used to evaluate performance of VDrift code. VDrift provides its own in-game profiling system, or it may produce output suitable for the GNU gprof profiler.
When VDrift is run with the
-profiling command-line option, certain parts of the game code (determined by the developers and hard-coded in the source) are evaluated as the game runs.
During execution, each profiled subsystem of the game is listed along the left side of the game window, along with the amount of time spent on that subsystem during the last tick. After VDrift exits, summarized profiling information is output to the stdout stream, including the percentage of time spent in each subsystem.
Profiling with gprof
Compiling with the profiling option enabled:
After exiting, run gprof on the executable: