▲ | ducktective 6 days ago | ||||||||||||||||||||||
I think you are very experienced in this subject. Can you explain what's wrong with WebGPU? Doesn't it utilize like 80% of the cool features of the modern GPUs? Games and ambitious graphics-hungry applications aside, why aren't we seeing more tech built on top of WebGPU like GUI stacks? Why aren't we seeing browsers and web apps using it? Do you recommended learning it (considering all the things worth learning nowadays and rise of LLMs) | |||||||||||||||||||||||
▲ | MindSpunk 6 days ago | parent | next [-] | ||||||||||||||||||||||
WebGPU is about a decade behind in feature support compared to what is available in modern GPUs. Things missing include: - Bindless resources - RT acceleration - 64-bit image atomic operations (these are what make nanite's software rasterizer possible) - mesh shaders It has compute shaders at least. There's a lot of less flashy to non-experts extensions being added to Vulkan and D3D12 lately that removes abstractions that WebGPU cant have without being a security nightmare. Outside of the rendering algorithms themselves, the vast majority of API surface area in Vulkan/D3D12 is just ceremony around allocating memory for different purposes. New stuff like descriptor buffers in Vulkan are removing that ceremony in a very core area, but its unlikely to ever come to WebGPU. fwiw some of these features are available outside the browser via 'wgpu' and/or 'dawn', but that doesn't help people in the browser. | |||||||||||||||||||||||
▲ | johncolanduoni 6 days ago | parent | prev | next [-] | ||||||||||||||||||||||
For beginner-to-intermediate raster use cases where you want to direct the GPU yourself, WebGPU will cover most of what you're looking for with reasonably low cognitive overhead. It's at a roughly DX11/Metal level of abstraction, but with some crucial modernizations that reduce friction between WebGPU and the underlying APIs (pipeline layouts being the biggest one). The main things it's missing for more advanced raster use cases aren't really GPU features as such, but low-level control over the driver. Unlike Vulkan/DX12, it does not permit (or require) you to manage allocations of individual resources in GPU memory, or perform your own CPU/GPU and GPU/GPU synchronization. The rationale (as I recall from some of the people working on the standard talking on GitHub issues or somewhere similar) was that the computational overhead of verifying that you've done these things correctly erases the gains from giving the user this level of control. For the web platform, verification that you're not going to corrupt memory or expose undefined driver behavior is non-negotiable. This explanation makes sense to me, and I haven't really heard anyone put forward a generalizable scheme that allows you Vulkan levels of control with efficient verification. | |||||||||||||||||||||||
▲ | 3836293648 6 days ago | parent | prev [-] | ||||||||||||||||||||||
First of all WebGPU has only been supported in Chrome for a few months and Firefox in the next release. And that's just Windows. We haven't had enough time to develop anything really. Secondly, the WebGPU standard is like Vulkan 1.0 and is cumbersome to work with. But that part is hearsay, I don't have much experience with it. | |||||||||||||||||||||||
|