[Mesa-dev] [PATCH 1/4] mesa: Add new MESA_multithread_makecurrent extension.

Jakob Bornecrantz wallbraker at gmail.com
Sat Feb 26 15:18:38 PST 2011

On Tue, Feb 22, 2011 at 10:08 PM, Eric Anholt <eric at anholt.net> wrote:
> On Tue, 22 Feb 2011 11:57:38 -0800, Ian Romanick <idr at freedesktop.org> wrote:
>> Hash: SHA1
>> On 02/21/2011 02:41 PM, Eric Anholt wrote:
>> > This extension allows a client to bind one context in multiple threads
>> > simultaneously.  It is then up to the client to manage synchronization of
>> > access to the GL, just as normal multithreaded GL from multiple contexts
>> > requires synchronization management to shared objects.


>> We may need to make the new behavior opt-in per-context anyway.  This
>> changes some very subtle and touchy GL behaviors, so some of these
>> changes may have unforeseen affects on existing apps.  Changing these
>> things always makes me nervous.  Over the years we've all independently
>> discovered that MakeCurrent and SwapBuffers are like Koch snowflakes...
>> there are *only* corner cases.
> GL has in the past changed things that were errors to not be errors to
> extend functionality and make the GL more useful -- see, for example,
> the deltas between GL_EXT_framebuffer_object to
> GL_ARB_framebuffer_object, which didn't first introduce a
> GL_DONT_THROW_ERRORS_FOR_LUMINANCE_FBOS knob.  I don't see why we should
> make the API even harder to access just to preserve an error return.

The difference is race conditions galore with no defined behavior vs
well defined behavior with just returning a error code. This needs to
be opt in.

Cheers Jakob.

More information about the mesa-dev mailing list