Phyronnaz / UECompileTimesVisualizer

Debug compile times in Unreal Engine & MSVC projects
MIT License
142 stars 14 forks source link
unreal-engine

Unreal Engine & MSVC Compile Times Visualizer




This program is outdated

In recent Unreal Engine versions, you should be able to just set bPrintToolChainTimingInfo to true in your BuildConfiguration.xml (see below).

You can then compile Engine\Source\Programs\Windows\CompileTimeAnalyzer and use it to load the .timing files located in your Intermediate folder.

The Compile Score VS extension also works great with Unreal if you want to see how much you're spending including files: https://marketplace.visualstudio.com/items?itemName=RamonViladomat.CompileScore2022




Previous Readme

Note: as this is using a disk visualizer as output, the following convention is used:

1MB = 1s | 1B = 1 micro second

What is this

It's a frontend for the msvc timing output log. With it you'll be able to see which function takes time to compile, which headers are included by your files and how expensive they are...

Basically if you want to speed up your compilation in UE or in a project using MSVC this should help a lot :)

Links

MSVC dev team blog post about compiler speed

Aras P. blog post about compile times

How to add PCHs in UE

UE Forum thread

Usage

Unreal Engine

MSVC

Script args

First arg: log file, defaults to Log.txt

Second arg: destination, defaults to result

Outputs

Most included files

The script will print the headers and the number of times they were included. This can be used to decide which headers should go in a PCH.

Includes

See which headers are included by your files, and how long they took to include.

Classes

See which classes are compiled in your files, and how long it took.

Functions

See which functions are compiled in your files, and how long it took.