[Mesa-dev] [RFC 2/2] glx: drop GLX_MESA_multithread_makecurrent support

Timothy Arceri tarceri at itsqueeze.com
Thu Apr 20 02:03:19 UTC 2017


On 20/04/17 10:53, Eric Anholt wrote:
> Timothy Arceri <tarceri at itsqueeze.com> writes:
> 
>> This extension is not supported by GLVND, also as far
>> as I can tell this extension requires us to do extra
>> locking for objects that are not normaly shared across
>> contexts, like vertex array and pipeline objects.
> 
> Can you explain how it would require extra locking?  The extension
> requires that the user not enter the same GL context twice at the same
> time -- is there something else missing?
> 

So you can't end up with tread 1 calling glGenVertexArrays() while 
thread 2 does some other call that requires a lookup of the vertex array 
object hash table (which could currently be in the middle of rehashing 
from the insert in glGenVertexArrays())?

I didn't see anything that forbids this. It's totally possible I'm 
misunderstanding this extension, if you could set me straight that would 
be great.

My thinking is that we should be able to do something like this:

https://github.com/tarceri/Mesa/commit/7e036b95012c709acf9ffeee575c17e274478953


More information about the mesa-dev mailing list