UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
Benchmark.h File Reference
#include "CoreGlobals.h"
#include "CoreTypes.h"
#include "HAL/PlatformTime.h"
#include "Math/NumericLimits.h"

Go to the source code of this file.

Macros

#define UE_BENCHMARK(NumRuns, ...)   { TRACE_CPUPROFILER_EVENT_SCOPE_STR(TEXT(#__VA_ARGS__)); Benchmark<NumRuns>(TEXT(#__VA_ARGS__), __VA_ARGS__); }
 

Functions

template<uint32 NumRuns, typename TestT >
void Benchmark (const TCHAR *TestName, TestT &&TestBody)
 

Macro Definition Documentation

◆ UE_BENCHMARK

#define UE_BENCHMARK (   NumRuns,
  ... 
)    { TRACE_CPUPROFILER_EVENT_SCOPE_STR(TEXT(#__VA_ARGS__)); Benchmark<NumRuns>(TEXT(#__VA_ARGS__), __VA_ARGS__); }

Function Documentation

◆ Benchmark()

template<uint32 NumRuns, typename TestT >
void Benchmark ( const TCHAR TestName,
TestT &&  TestBody 
)