commit | 5e1ca532697fcd2daf0841d266afad2d7326c055 | [log] [tgz] |
---|---|---|
author | Jiawei Shao <jiawei.shao@intel.com> | Fri Jun 04 05:12:06 2021 +0000 |
committer | Dawn LUCI CQ <dawn-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri Jun 04 05:12:06 2021 +0000 |
tree | 239c7bb41155e28c614b77e262c37e29379f3d71 | |
parent | 2adb3c83e4b44586df995f047ee1678bdc81d17d [diff] |
D3D12: Support creating compute pipeline asynchronously This patch implements the asynchronous path of CreateComputePipelineAsync on D3D12 backend with the basic framework of the dawn_unittest AsyncTaskTest.Basic. 1. Call the constructor of dawn_native::d3d12::ComputePipeline in the main thread. 2. Execute dawn_native::ComputePipelineBase::Initialize() (a virtual function) asynchronously. 3. Ensure every operation in dawn_native::d3d12::ComputePipeline::Initialize() is thread-safe (PersistentCache). 4. Save all the return values (pipeline object or error message, userdata, etc) in a CreateComputePipelineAsyncWaitableCallbackTask object and insert this callback task into CallbackTaskManager. 5. In Callback.Finish(): - Insert the pipeline object into the pipeline cache if necessary - Call WGPUCreateComputePipelineAsyncCallback Note that as we always handle the front-end pipeline cache in the main thread, we don't need to make it thread-safe right now. BUG=dawn:529 TEST=dawn_end2end_tests Change-Id: I7eba2ce550b32439a94b2a4d1aa7f1b3383aa514 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/47900 Commit-Queue: Jiawei Shao <jiawei.shao@intel.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
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.