d3d11: Cache view/binding pointer identity instead of ComPtr BindGroupTracker previously cached ComPtr<T> per binding slot to detect redundant Set* calls, requiring an atomic COM AddRef/Release on every bind even when the underlying view was unchanged. Command recording is already serialized under the device lock, so the atomicity bought nothing but cost an interlocked op per binding per draw/dispatch. Instead, track only the bound resource's pointer identity, compared but never dereferenced, so a stale/reused value can at worst cause a missed rebind, never a use-after-free. In practice this shouldn't even happen, since D3D11 holds its own reference on a bound resource for as long as it stays bound. Buffer::UseAsSRV/UseAsUAV public methods now take a lambda, scoping the raw view pointer's validity to the callback. Bug: 505330398 Change-Id: I5adade914b006eb05ea4530c6e5ec61526402c6a Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/304397 Commit-Queue: Quyen Le <lehoangquyen@google.com> Reviewed-by: Quyen Le <lehoangquyen@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Dawn is an open-source and cross-platform implementation of the WebGPU standard. More precisely it implements webgpu.h that is a one-to-one mapping with the WebGPU IDL. Dawn is meant to be integrated as part of a larger system and is the underlying implementation of WebGPU in Chromium.
Dawn provides several WebGPU building blocks:
webgpu.h version that Dawn implements.webgpu.h.Helpful links:
Developer documentation:
User documentation: (TODO, figure out what overlaps with the webgpu.h docs)
BSD 3-Clause License, please see LICENSE.
This is not an officially supported Google product.