gpu-dawn: default to release version of Dawn by default (even in debug builds) #464

Closed
opened 2022-08-19 20:17:40 +00:00 by emidoots · 0 comments
emidoots commented 2022-08-19 20:17:40 +00:00 (Migrated from github.com)

The nanovg Mach backend by dweiller on Matrix is ~15FPS in a debug build, and much much faster in a release build. Granted, it's not using WebGPU optimally, but it goes to show the impact many WebGPU API calls can have in a debug vs. release build.

Dawn already has a fair amount of debugging/validation at runtime, since after all it is used in Chrome as a release build not a debug build, so we should default to using a release build of Dawn even when building a debug Zig application.

Similar to how we have -Ddawn-from-source we can have -Ddawn-debug to use a debug build, though.

TL;DR:

  • Better performance
  • Not much worse debugging (Chrome uses release builds after all)
  • Less potential UBSAN issues (e.g. these are causing Windows examples to fail right now)
  • May improve linker times(?)
The nanovg Mach backend by dweiller on Matrix is ~15FPS in a debug build, and much much faster in a release build. Granted, it's not using WebGPU optimally, but it goes to show the impact many WebGPU API calls can have in a debug vs. release build. Dawn already has a fair amount of debugging/validation at runtime, since after all it is used in Chrome as a release build not a debug build, so we should default to using a release build of Dawn even when building a debug Zig application. Similar to how we have `-Ddawn-from-source` we can have `-Ddawn-debug` to use a debug build, though. TL;DR: * Better performance * Not much worse debugging (Chrome uses release builds after all) * Less potential UBSAN issues (e.g. these are causing Windows examples to fail right now) * May improve linker times(?)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
hexops/mach#464
No description provided.