Measuring Startup Asset Load Times in Unreal Engine

This article is an excerpt from a presentation I did for the Toronto Unreal Engine Meetup on hints and tips with Unreal Engine.

In some cases you may want to understand what assets are being loaded at startup/load of your Unreal Engine game. Tracking down issues during this time can be tricky because there’s not many UE4 systems initialized that you can hook into to understand the problem.

One of the ways to assist with this is the -LoadTimeFile command line flag. An example usage would be…

MyGame.exe -LoadTimeFile

Once your game launches you’ll get a stat readout on screen…

So keep in mind you will need to run the console command…

stat stopfile 

to stop the profiling process and capture a .ue4stats file that can be analyzed afterwards. This can be run from the in game console…

The file is saved under your games’ Saved folder…

<your-game>/Saved/Profiling/UnrealStats/

Under here you will find a sub-folder named with a LoadTimeFile prefix containing the .ue4stats file

You can then open this file in Unreal Frontend (also known as Session Frontend) to analyze specific asset load times.

Leave a Reply

Your email address will not be published. Required fields are marked *