glthread: implement glGetUniformLocation without syncing
authorMarek Olšák <marek.olsak@amd.com>
Thu, 19 Aug 2021 00:16:38 +0000 (20:16 -0400)
committerMarge Bot <eric+marge@anholt.net>
Tue, 24 Aug 2021 15:24:07 +0000 (15:24 +0000)
commitdb9ffc55618b9de2a2ec8b7c5ff33ee815b3421f
tree9bcb398c832cf473e76ae715ad841567ba72bd38
parent625f00d37cd00b13adcf059ae7dbe434d54c6f41
glthread: implement glGetUniformLocation without syncing

We already have the infrastructure for querying shader program properties
without syncing. This just uses it. _mesa_error_glthread_safe sets a GL
error from the producer thread.

This decreases CPU overhead for viewperf/snx.

Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12490>
src/mapi/glapi/gen/gl_API.xml
src/mesa/main/glthread_shaderobj.c
src/mesa/main/uniforms.c
src/mesa/main/uniforms.h