X Tutup
Skip to content

Add pages on graphics debugging and profiling#11253

Open
Calinou wants to merge 1 commit intogodotengine:masterfrom
Calinou:add-graphics-debugging-profiling
Open

Add pages on graphics debugging and profiling#11253
Calinou wants to merge 1 commit intogodotengine:masterfrom
Calinou:add-graphics-debugging-profiling

Conversation

@Calinou
Copy link
Member

@Calinou Calinou commented Sep 2, 2025

This documentation is aimed at new and returning rendering contributors (as well as users wishing to get more information than with Godot's own visual profiler). It aims to describe basic usage of GPU debugging/profiling tools on Godot projects.

TODO

  • Document how to make use of rendering markers (such as Render Sky) in RenderDoc. Starting Godot with --verbose doesn't seem to suffice for Vulkan on Linux at least (although it works on Windows in NSight).
    • If you can figure it out, let me know.
  • Document how to access shader sources in RenderDoc and NSight. Using --generate-spirv-debug-info currently doesn't work due to an engine bug.
  • Document Radeon GPU Profiler in graphics profiling page.
  • Document Radeon Memory Visualizer in graphics profiling page.

@Calinou Calinou added content:new page Issues and PRs related to creation of new documentation pages for new or undocumented features topic:rendering area:engine details Issues and PRs related to the Engine Details section of the documentation labels Sep 2, 2025
@Calinou Calinou force-pushed the add-graphics-debugging-profiling branch 2 times, most recently from 6e9e998 to a0c161d Compare September 2, 2025 17:15
@Ivorforce
Copy link
Member

Needs rebase after #11188.

@Calinou Calinou force-pushed the add-graphics-debugging-profiling branch 2 times, most recently from 054a1b6 to 908acbd Compare September 13, 2025 21:59
TODO:

- Document how to make use of markers in RenderDoc.
  Using `--verbose` doesn't seem to suffice for Vulkan on Linux at least
  (although it works on Windows in NSight).
- Document how to access shader sources in RenderDoc.
  Using `--generate-spirv-debug-info` currently doesn't work due to an engine bug.
- Document Radeon GPU profiling in graphics profiling page.
- Document Radeon Memory Visualizer in graphics profiling page.
@Calinou Calinou force-pushed the add-graphics-debugging-profiling branch from 908acbd to 47a875f Compare September 14, 2025 01:11
@akien-mga
Copy link
Member

I think it's a great first step, should we try to get this merged as is / after rebase and leave the other TODOs for a future PR?

Copy link
Member

@AThousandShips AThousandShips left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Calinou Calinou marked this pull request as ready for review December 20, 2025 00:18
Comment on lines +23 to +26
Additionally, when running Godot through a graphics debugger, you should
always run it using the ``--generate-spirv-debug-info``
:ref:`command line argument <doc_command_line_tutorial>`. Otherwise, source-level
shader debugging won't work.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this isn't needed if users are using a debug build. So the above paragraph may also be incorrect

Copy link
Member Author

@Calinou Calinou Jan 22, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have checked the source it's not always enabled in debug builds: https://github.com/godotengine/godot/blob/c3058391d7bd1a13481c393061c164c24ec99685/drivers/vulkan/rendering_device_driver_vulkan.cpp#L566-L568

However, the option is unused in D3D12 since it's not supported there: https://github.com/godotengine/godot/blob/c3058391d7bd1a13481c393061c164c24ec99685/modules/glslang/register_types.cpp#L75-L81

When it comes to D3D12, we need to document use_pix=yes in the Compiling for Windows documentation, as it's not enabled by default, even in debug builds.

Edit: Done in #11657.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:engine details Issues and PRs related to the Engine Details section of the documentation content:new page Issues and PRs related to creation of new documentation pages for new or undocumented features topic:rendering

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

X Tutup