[Mesa-dev] [PATCH 2/3] glx: add interface for flushing a drawable and throttling at the same time

Eric Anholt eric at anholt.net
Fri Nov 9 09:36:36 PST 2012


Marek Olšák <maraeo at gmail.com> writes:

> The motivation is to prevent a double flush in Gallium.
>
> Gallium flushes in __DRI2flushExtensionRec::flush and dri2Throttle.
> This will help consolidate the flushing.

It looks like you've changed a bunch of drivers to expose
__DRI2_FLUSH_VERSION (4) instead of 3, without making them implement the
new interface, so they'd just crash.  Please continue to use explicit
numbers in drivers, so that drivers don't break when the loader
interface is revved without updating them.

More generally, I think our loader vs driver implementation of
swapbuffers is backwards.  I'd rather see the driver get a
swapbuffers-specific call as immediately as possible from the loader,
let it handle flushing and throttling, and have it call to dri2 part of
the loader for actually telling the other side to go swap the buffers.

If we had that, then hopefully getting the flushes down to 1 is obvious,
since the driver would do that after any other things it does (like msaa
resolves) right before asking the server for the swap.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20121109/ec5d9412/attachment.pgp>


More information about the mesa-dev mailing list