Bug 264111 - [WebGPU] Buffer synchronization is implemented incorrectly leading to data races between the CPU and GPU
Summary: [WebGPU] Buffer synchronization is implemented incorrectly leading to data ra...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGPU (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-11-02 12:59 PDT by Mike Wyrzykowski
Modified: 2023-11-03 12:14 PDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Wyrzykowski 2023-11-02 12:59:29 PDT
[WebGPU] Buffer synchronization is implemented incorrectly leading to data races between the CPU and GPU

Specifically, calling GPUCommandEncoder.copyXToBuffer() and then mapping the buffer contents returns the pointer, but the copy command may still be in flight.

This leads to data races
Comment 1 Radar WebKit Bug Importer 2023-11-02 12:59:44 PDT
<rdar://problem/117869389>
Comment 2 Mike Wyrzykowski 2023-11-03 00:21:41 PDT
Pull request: https://github.com/WebKit/WebKit/pull/19938
Comment 3 EWS 2023-11-03 12:14:34 PDT
Committed 270195@main (1ab3947e3854): <https://commits.webkit.org/270195@main>

Reviewed commits have been landed. Closing PR #19938 and removing active labels.