UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FExclusiveLoadPackageTimeTracker Class Reference

#include <ExclusiveLoadPackageTimeTracker.h>

Classes

struct  FScopedEndLoadTracker
 
struct  FScopedPackageTracker
 
struct  FScopedPostLoadTracker
 

Static Public Member Functions

static UE_FORCEINLINE_HINT void PushLoadPackage (FName PackageName)
 
static UE_FORCEINLINE_HINT void PopLoadPackage (UPackage *LoadedPackage)
 
static bool PushPostLoad (UObject *PostLoadObject)
 
static UE_FORCEINLINE_HINT void PopPostLoad (UObject *PostLoadObject)
 
static void PushEndLoad ()
 
static UE_FORCEINLINE_HINT void PopEndLoad ()
 
static UE_FORCEINLINE_HINT void DumpReport (const TArray< FString > &Args)
 
static UE_FORCEINLINE_HINT void ResetReport ()
 
static double GetExclusiveLoadTime (FName PackageName)
 
static double GetInclusiveLoadTime (FName PackageName)
 

Detailed Description

A singleton to keep track of the exclusive load time of every package. Also reports inclusive load time for convenience. The code that loads packages "pushes" a load on the tracker which will record the time the package started loading. Later that package will be "popped" which will cause the tracker to record the time spent. If another package is pushed while this is happening, it will pause the time recorded from the first package and start a new time for the second. This is recursive. DumpReport() can be used to log out all the recorded values in a couple different ways to get an idea about what packages are the slowest to load.

Member Function Documentation

◆ DumpReport()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::DumpReport ( const TArray< FString > &  Args)
inlinestatic

Displays the data gathered in various ways.

◆ GetExclusiveLoadTime()

static double FExclusiveLoadPackageTimeTracker::GetExclusiveLoadTime ( FName  PackageName)
inlinestatic

Returns the load time for the specified package, excluding its dependencies

◆ GetInclusiveLoadTime()

static double FExclusiveLoadPackageTimeTracker::GetInclusiveLoadTime ( FName  PackageName)
inlinestatic

Returns the load time for the specified package, including its dependencies

◆ PopEndLoad()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::PopEndLoad ( )
inlinestatic

Records some time spent in "EndLoad"

◆ PopLoadPackage()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::PopLoadPackage ( UPackage LoadedPackage)
inlinestatic

Records a time and stats for the loaded package.

◆ PopPostLoad()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::PopPostLoad ( UObject PostLoadObject)
inlinestatic

Records a time and stats for the loaded package. Optionally provide the loaded asset if it is known, otherwise the asset in the package is detected.

◆ PushEndLoad()

static void FExclusiveLoadPackageTimeTracker::PushEndLoad ( )
inlinestatic

Starts a time for time spent in "EndLoad"

◆ PushLoadPackage()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::PushLoadPackage ( FName  PackageName)
inlinestatic

Starts a time for the specified package name.

◆ PushPostLoad()

static bool FExclusiveLoadPackageTimeTracker::PushPostLoad ( UObject PostLoadObject)
inlinestatic

Starts a time for the specified package name.

◆ ResetReport()

static UE_FORCEINLINE_HINT void FExclusiveLoadPackageTimeTracker::ResetReport ( )
inlinestatic

Resets the data.


The documentation for this class was generated from the following file: