WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
283286
[GTK][WPE][Skia] Add GPU synchronization primitives to NativeImage/ImageBuffer for Skia
https://bugs.webkit.org/show_bug.cgi?id=283286
Summary
[GTK][WPE][Skia] Add GPU synchronization primitives to NativeImage/ImageBuffe...
Nikolas Zimmermann
Reported
2024-11-18 01:43:46 PST
For the planned threaded GPU rendering mode we need a way to mark a NativeImage/ImageBuffer "as done", to inject a fence in the GL command stream, that we can wait on at a later point in time to guarantee that all operations finished. Therefore I propose to add Skia specific functions to ImageBuffer(Backend)/NativeImageBackend: - finishAcceleratedRenderingAndCreateFence() Used to notify the underlying SkSurface, that it should flush all pending rendering operations and submit the work to the GPU. Afterwards inject a fence into the GL command stream, so that we we can wait upon completion at a later point, before attempting to use the ImageBuffer/NativeImage. - waitForAcceleratedRenderingFenceCompletion() Performs a 'serverWait()' operation on the GLFence, previously created by finishAcceleratedRenderingAndCreateFence(). This instructs to GPU to await completion of the previous rendering. finishAcceleratedRenderingAndCreateFence() will be used during DisplayList recording, whenever an ImageBuffer/NativeImage resource is used, upon entering the DisplayList::ResourceHeap cache. waitForAcceleratedRenderingFenceCompletion() will be used during DisplayList replaying, whenever an ImageBuffer/NativeImage resource is extracted from the DisplayList::ResourceHeap cache.
Attachments
Add attachment
proposed patch, testcase, etc.
Nikolas Zimmermann
Comment 1
2024-11-18 02:24:33 PST
Pull request:
https://github.com/WebKit/WebKit/pull/36794
EWS
Comment 2
2024-11-18 16:04:45 PST
Committed
286767@main
(774fd3dddd84): <
https://commits.webkit.org/286767@main
> Reviewed commits have been landed. Closing PR #36794 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug