commit | de078bad8d70d2ab7f216a63ea7024149d350489 | [log] [tgz] |
---|---|---|
author | Le Hoang Quyen <lehoangquyen@chromium.org> | Thu Mar 23 15:16:46 2023 +0000 |
committer | Dawn LUCI CQ <dawn-scoped@luci-project-accounts.iam.gserviceaccount.com> | Thu Mar 23 15:16:46 2023 +0000 |
tree | a7e933d53afed8c1671a4b0b1011497e62b151cd | |
parent | f3593952882dddfecb2d06210f8cc1eb67b952d2 [diff] |
Forward callbacks to Instance after Device is destroyed. When InstanceBase::ProcessEvents() iterates through list of devices, one device might be being destructed on another thread. Even if we try to increase ref count of that device inside the ProcessEvents(), the device might be in the middle of destructor call on another thread, increasing the ref count is invalid in this case. This CL attempts to fix this issue by removing the device's pointer from InstanceBase earlier: when DeviceBase::WillDropLastExternalRef() is called. After this point, any callback registered to this device will be forwarded to InstanceBase's callback queue instead. Bug: dawn:752 Change-Id: I8ae86575e34f753e52a76f5fc774bbb5366a1b85 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/124281 Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Quyen Le <lehoangquyen@chromium.org> Reviewed-by: Loko Kung <lokokung@google.com>
Dawn is an open-source and cross-platform implementation of the work-in-progress 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)
(TODO)
Apache 2.0 Public License, please see LICENSE.
This is not an officially supported Google product.