# Profile and debug when using variable rate shading

> View performance improvements and debug a project that uses variable rate shading.

Use the Rendering Debugger or Unity Profiler to monitor GPU frame time and measure performance improvements with variable rate shading. To visualize the shading rate image for render passes that use variable rate shading, use the Frame Debugger.

## Use the Rendering Debugger

1. Open the **Rendering Debugger** window (menu: **Window** > **Analysis** > **Rendering Debugger**).

2. Select the **Display Stats** panel.

   > **Note:**
   >
   > The **Display Stats** panel is only visible during Play mode.

3. In the **Frame Stats** section, view the GPU frame time metrics.

After implementing variable rate shading, you can observe lower frame time values indicating improved GPU performance.

For more information, refer to the [Rendering Debugger window reference for URP](/engine/6000.3/manual/analysis/graphics-performance-profiling/in-urp/understand-performance/rendering-debugger/reference.md).

## Use the Unity Profiler

1. Open the **Profiler** window (menu: **Window** > **Analysis** > **Profiler**).
2. In the **Profiler** window, select the **CPU Usage** module.
3. In the **Timeline** or **Hierarchy** view for the selected module, look for the [`Gfx.WaitForPresentOnGfxThread`](/engine/6000.3/manual/analysis/profiler/markers.md#rendering) profiler marker.

A reduction in the `Gfx.WaitForPresentOnGfxThread` marker indicates improved GPU performance.

For more information, refer to [Profiler markers](/engine/6000.3/manual/analysis/profiler/customizing/adding-information-code/intro.md#profiler-markers).

## Use the Frame Debugger

1. Open the **Frame Debugger** window (menu: **Window** > **Analysis** > **Frame Debugger**).
2. Enable the Frame Debugger.
3. In the events list, select the rendering event from a pass that uses variable rate shading.
4. In the **Event Information** panel, expand the **Details** section.
5. Locate the **Shading Rate Image** property for the color visualization of the shading rate image attachment.

## Additional resources

* [GPU Usage Profiler module](/engine/6000.3/manual/analysis/graphics-performance-profiling/profile-rendering/profiler-gpu.md)
* [Frame Debugger Event Information reference](/engine/6000.3/manual/analysis/graphics-performance-profiling/profiling/frame-debugger-window-event-information.md#details)
* [Implement variable rate shading](/engine/6000.3/manual/analysis/graphics-performance-profiling/in-urp/variable-rate-shading/implementation.md)
* [Introduction to variable rate shading](/engine/6000.3/manual/analysis/graphics-performance-profiling/in-urp/variable-rate-shading/introduction.md)
