Skip to content

gallium: Add optional pipe_context to flush_frontbuffer

Jesse Natalie requested to merge jenatali/mesa:flush-frontbuffer-context into master

It's hooked up in all the pipe wrapper drivers, and all the frontends except a couple places in glx/xlib.

This enables a more efficient path for drivers which use swrast's Present, but hardware rendering (e.g. d3d12, zink). With this, we can make a follow-on change to the d3d12 driver (which I'll send separately) to increase WSL perf roughly 10x. It's going to take us quite a while to get a more direct path of sharing resources from GL -> X/Wayland -> Windows, so this software path (hooked up for drisw in !7937 (merged)) is all we'll be able to use in the meantime, and I'd like for performance to be reasonable.

Almost every frontend can't even make it to flush_frontbuffer without a context. The wgl one can, so it's optional there, and I didn't chase back very far in the glx/xlib frontend to try to hook it up there. Every other caller will provide a valid context, or just not call the function.

Merge request reports