2

Is there any debugging tools for WebGPU?

Something like RenderDoc app that I can see the buffers and frames.

2 Answers 2

1

WebGPU Recorder

WebGPU Recorder is a debugging tool for WebGPU.

It is a playback recorder, designed to capture all WebGPU commands and data, with the ability to play back the commands to recreate the render.

It captures all WebGPU commands, buffers, and textures, over a given number of frames. It will then generate an HTML file containing javascript with all of the WebGPU commands recorded. This generated HTML file can be opened in the browser to play back the recording.

This can be used to diagnose issues with WebGPU rendering by eliminating everything but the raw WebGPU commands. This is also very helpful for submitting self-contained reproduction examples for bug reports.

https://github.com/brendan-duncan/webgpu_recorder

1
  • It sounds a great tools. I m going to test it. Thank you! Commented Feb 28, 2023 at 11:01
3

There's the WebGPU Inspector. Which looks like directly what you were asking for

There's also the WebGPU Dev Extension which does things like

  • gives you stack traces on errors (WebGPU doesn't directly since it's has async error reporting)
  • throws on encoder errors (normal encoder errors happen late, far from the call site)
  • lets you force low-power, high-performance on a dual GPU machine
  • lets you disable and/or remove WebGPU (so you can test your app handles it)
  • lets you disable individual WebGPU extensions (again to test those paths in your or other apps)
  • lets you set breakpoints on WebGPU API functions (find out where in the code importExternalTexture is called for example
  • will auto add labels and meta-data to make debugging easier.
  • 🌈 🦄 🎁

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.