Navigation
API > API/Runtime > API/Runtime/Core
Stack tracker. Used to identify callstacks at any point in the codebase.
| Name | FStackTracker |
| Type | struct |
| Header File | /Engine/Source/Runtime/Core/Public/Containers/StackTracker.h |
| Include Path | #include "Containers/StackTracker.h" |
Syntax
struct FStackTracker
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FStackTracker
(
StackTrackerUpdateFn InUpdateFn, |
Constructor, initializing all member variables | Containers/StackTracker.h |
Structs
| Name | Remarks |
|---|---|
| FCallStack | Helper structure to capture callstack addresses and stack count. |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| StackTrackerDeleteUserDataFn | void(*) | Used to delete a provided userdata pointer e.g. call the correct destructor | Containers/StackTracker.h |
| StackTrackerReportFn | void(*) | Used to optionally report information based on the current stack | Containers/StackTracker.h |
| StackTrackerUpdateFn | void(*) | Used to optionally update the information currently stored with the callstack | Containers/StackTracker.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| MAX_BACKTRACE_DEPTH | int32 | Maximum number of backtrace depth. | Containers/StackTracker.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AliasMap | TMap< uint64, uint64 > | Mapping an address to an arbitrary alias of that address. | Containers/StackTracker.h | |
| bAvoidCapturing | bool | Whether we are currently capturing or not, used to avoid re-entrancy. | Containers/StackTracker.h | |
| bIsEnabled | bool | Whether stack tracking is enabled. | Containers/StackTracker.h | |
| CallStacks | TArray< FCallStack > | Array of unique callstacks. | Containers/StackTracker.h | |
| CRCToCallStackIndexMap | TMap< uint32, int32 > | Mapping from callstack CRC to index in callstack array. | Containers/StackTracker.h | |
| DeleteUserDataFn | StackTrackerDeleteUserDataFn | Used to delete a provided userdata pointer e.g. call the correct destructor | Containers/StackTracker.h | |
| ReportFn | StackTrackerReportFn | Used to optionally report information based on the current stack | Containers/StackTracker.h | |
| StartFrameCounter | uint64 | Frame counter at the time tracking was enabled. | Containers/StackTracker.h | |
| StopFrameCounter | uint64 | Frame counter at the time tracking was disabled. | Containers/StackTracker.h | |
| StringAliasMap | TMap< FString, uint64 > | Mapping an string to an arbitrary alias of that address. | Containers/StackTracker.h | |
| UpdateFn | StackTrackerUpdateFn | Used to optionally update the information currently stored with the callstack | Containers/StackTracker.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void CaptureStackTrace
(
int32 EntriesToIgnore, |
Captures the current stack and updates stack tracking information. | Containers/StackTracker.h | |
void DumpStackTraces
(
int32 StackThreshold, |
Dumps capture stack trace summary to the passed in log. | Containers/StackTracker.h | |
void ResetTracking () |
Resets stack tracking. | Containers/StackTracker.h | |
void ToggleTracking () |
Toggles tracking. | Containers/StackTracker.h | |
void ToggleTracking
(
bool bEnable, |
Containers/StackTracker.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void DefaultDeleteUserDataFn
(
void* UserData |
Containers/StackTracker.h |