Skip to content

GPU Memory Profiling

Jeremy Ong edited this page Mar 17, 2022 · 2 revisions

NOTE: This page pertains to the development branch of O3DE only

GPU Memory Profiling is currently provided from the Dear ImGui interface. To access the memory profiler, press the Ctrl+Home hotkey with the viewport active and select the following menu option:

image

In the subsequently opened capture dialog, select the Enable GpuMemoryView checkbox to bring up the Gpu Memory Profiler window as seen below (a more recent screenshot will also show buttons to save the memory capture to CSV or load an existing capture from CSV):

image

The Capture button produces a memory snapshot that results in tabulated and treemap-organized data to analyze memory allocations in the renderer. In this empty scene, hitting Capture will change the window to look as follows (after resizing the window):

image

The top section has a few options to enable the host-local (e.g. CPU) and device-local (e.g. GPU) memory treemap views, and checkboxes to filter individual entries based on memory type. Below there are two tables corresponding to aggregated per-pool statistics, and individual allocations below. The fragmentation percentage column reports (as a percentage), 1 minus the ratio of the largest free block to the total amount of free memory in the parent buffer or pool.

The individual allocation table at the bottom shows more granular information per allocation, the parent pool the allocation was obtained from, and the bind flags used.

For a more visual depiction of the memory usage, you may enable the Show host memory treemap or Show device memory treemap checkboxes to view the host or gpu memory distributions accordingly. For example, enabling the device memory treemap displays the following window:

image

To interpret the treemap, each allocation is represented by a single rectangle, which are grouped with sibling allocations from the same memory pool in larger subdivisions. The allocations may be hovered with a cursor to display statistics about the allocation in question or the parent pool. This view supports highlighting treemap entries by allocation type, and statistics for individual allocations may be pinned to the top using left-click selection. The following view demonstrates a selected entry and all texture memory highlighted to visualize the proportion of used memory occupied by texture data.

image

Clone this wiki locally