[Mesa-dev] Enable GLX TLS by default in Mesa?
Ian Romanick
idr at freedesktop.org
Tue Aug 13 14:18:51 PDT 2013
On 08/13/2013 12:04 PM, Vedran Rodic wrote:
> On Tue, Aug 13, 2013 at 7:19 PM, Kenneth Graunke <kenneth at whitecape.org> wrote:
>>
>>
>> As far as I know, --enable-glx-tls just makes things more efficient.
>>
>> Nothing should *rely* on it, or even be able to detect it...
>
> Dota 2 crashes without that option when loading the actual game map. I
> assumed it adds thread safety.
With TLS the context pointer and the dispatch pointer are stored in
thread local storage. Looking them up (which happens on every GL call)
is "fast."
Without TLS the context pointer and the dispatch pointer are stored
using pthread_setspecific / pthread_getspecific. Looking them up is
hella slow.
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list