diff options
author | cheyang <cheyang@bytedance.com> | 2020-12-25 16:20:43 +0800 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2020-12-28 12:23:59 +0000 |
commit | a7be48bdae90d7087df4d2e4d5261c37767395c9 (patch) | |
tree | f684dc9be5c25d83e014e43273459b2750b33ff7 | |
parent | 72390f063f2ce30b93edd9d640f75c867a60c567 (diff) |
mesa: glProgramBinary add resource_hash
reduce search time(E.g glGetUniformLocation) when use glProgramBinary
Signed-off-by: cheyang <cheyang@bytedance.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8238>
-rw-r--r-- | src/mesa/main/program_binary.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/main/program_binary.c b/src/mesa/main/program_binary.c index 8c2db255246..536201694c3 100644 --- a/src/mesa/main/program_binary.c +++ b/src/mesa/main/program_binary.c @@ -301,6 +301,8 @@ _mesa_program_binary(struct gl_context *ctx, struct gl_shader_program *sh_prog, return; } + _mesa_create_program_resource_hash(sh_prog); + /* From section 7.3 (Program Objects) of the OpenGL 4.5 spec: * * "If LinkProgram or ProgramBinary successfully re-links a program |