Navigation
API > API/Runtime > API/Runtime/Core
Description
AnsiMallocUntracked API: Malloc
Functions in the AnsiMallocUntracked API provide allocations from c++ or operating system allocations functions without going through an intermediate heap manager. Unlike AnsiMalloc API, these allocations are NOT tracked in Unreal's memory trackers. As usual with allocation functions, AnsiReallocUntracked and AnsiFreeUntracked should only be called on nullptr or on pointers returned from AnsiMallocUntracked or AnsiReallocUntracked.
This API exists only for cases where attempting to track the allocations causes a conflict. We prefer all allocations to be tracked so memory usage can be analyzed, so if no conflict exists or it can be worked around, callers should use AnsiMalloc API instead.
Callsites using the AnsiMallocUntracked API should document the conflict.
| Name | AnsiMallocUntracked |
| Type | function |
| Header File | /Engine/Source/Runtime/Core/Public/HAL/MallocAnsi.h |
| Include Path | #include "HAL/MallocAnsi.h" |
| Source | /Engine/Source/Runtime/Core/Private/HAL/MallocAnsi.cpp |
void * AnsiMallocUntracked
(
SIZE_T Size,
uint32 Alignment
)