Visualizing VGPR Pressure with Radeon™ GPU Analyzer 2.6

The latest version of the Radeon™ GPU Analyzer (RGA), 2.6, is now available.

RGA is an offline compiler and performance analysis tool for DirectX®, Vulkan®, SPIR-V™, OpenGL®, and OpenCL™. RGA and other tools can be downloaded as part of the Radeon Developer Tool Suite.

Radeon GPU Analyzer 2.6 introduces a new VGPR Pressure Visualization feature in the GUI application’s disassembly view.

This post will briefly show what this feature looks like in the RGA GUI and how it highlights VGPR pressure.

RGA

Radeon GPU Analyzer is an offline compiler and performance analysis tool for DirectX®, Vulkan®, SPIR-V™, OpenGL® and OpenCL™.

After successfully building your code with the RGA GUI app, you will notice a new column in the disassembly view named “VGPR pressure”.

The column header text format is “VGPR pressure (used x; allocated: y/256)”, which provides a summary for the entire shader, where ‘x’ gives the total VGPRs used by the current shader and ‘y’ gives the total number of VGPRs allocated.

Hovering over any of the column’s cells will show a tooltip that is designed to provide a summary of the live VGPR at that specific instruction and a hint about how many VGPRs need to be reduced to save a VGPR block at that instruction.

Note that VGPRs are allocated in blocks, which vary in size. The VGPR block size is determined by the target GPU and, in certain cases, by specific characteristics of the shader, such as the wave size it was compiled for. The hint indicates how many VGPRs need to be freed to free up an entire block of VGPRs at that point of the shader.

Note that, when generating the hint, the tool will take into account the target GPU and the relevant shader characteristics for determining the VGPR allocation block size.

When examining the VGPR pressure column cells, in addition to the numerical value, which gives the number of live VGPRs at that instruction, you will also notice a utilization bar that visualizes the VGPR usage and the VGPR block utilization. The emptier the utilization bar is, the less of the allocated VGPR block is being utilized, which means that fewer VGPRs would need to be reduced to free up that block.

vgpr_visualization_zoom_updated

The above screenshot shows a shader with a VGPR allocation block size of 8 VGPRs. You can see that different lines have different colors in their visualization bar depending on their live VGPR value. The bar’s color would be greener as the live VGPR value at that instruction gets closer to 0 and redder as the value gets closer to 256.

The lines where the visualization bar is full (where the VGPR usage value is a multiple of 8, like 104, 96, 88 etc.) show points in the shader where the VGPR allocation block is fully utilized. However, in lines where the bar is partially empty, not all allocated VGPRs are being used. The tooltip hint mentioned earlier will let you know how many VGPRs need to be reduced to free up that VGPR allocation block.

Get the Radeon Developer Tool Suite today!

The latest version of the Radeon Memory Visualizer is available as part of the Radeon Developer Tool Suite.

Related content

Radeon™ Developer Panel

The RDP provides a communication channel with the Radeon™ Adrenalin driver. It generates event timing data used by the Radeon™ GPU Profiler (RGP), and the memory usage data used by the Radeon™ Memory Visualizer (RMV).

RGA

Radeon™ GPU Analyzer

Radeon GPU Analyzer is an offline compiler and performance analysis tool for DirectX®, Vulkan®, SPIR-V™, OpenGL® and OpenCL™.

Amit Ben-Moshe

Amit Ben-Moshe

Amit Ben-Moshe is a Technical Lead and a Principal Member of Technical Staff at AMD. His postings are his own opinions and may not represent AMD’s positions, strategies or opinions. Links to third party sites are provided for convenience and unless explicitly stated, AMD is not responsible for the contents of such linked sites and no endorsement is implied.

Enjoy this blog post? If you found it useful, why not share it with other game developers?

You may also like...

If slide decks are what you’re after, you’ll find 100+ of our finest presentations here. Plus there’s a handy list of our product manuals!

Developer guides

Browse our developer guides, and find valuable advice on developing with AMD hardware, ray tracing, Vulkan, DirectX, UE4, and lots more.

Words not enough? How about pictures? How about moving pictures? We have some amazing videos to share with you!

The home of great performance and optimization advice for AMD RDNA™ 2 GPUs, AMD Ryzen™ CPUs, and so much more.

Product Blogs

Our handy product blogs will help you make good use of our tools, SDKs, and effects, as well as sharing the latest features with new releases.

Publications

Discover our published publications.