mesa: Uniform logging is very, very unlikely
authorIan Romanick <ian.d.romanick@intel.com>
Tue, 21 Oct 2014 00:02:55 +0000 (17:02 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Mon, 10 Nov 2014 12:25:40 +0000 (04:25 -0800)
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
src/mesa/main/uniform_query.cpp

index f971ba171a81330085c8005acfd3dc3ee1effdb6..32870d0c492a82f08aa1663d09a9f29c788ee87c 100644 (file)
@@ -634,7 +634,7 @@ _mesa_uniform(struct gl_context *ctx, struct gl_shader_program *shProg,
       return;
    }
 
-   if (ctx->_Shader->Flags & GLSL_UNIFORMS) {
+   if (unlikely(ctx->_Shader->Flags & GLSL_UNIFORMS)) {
       log_uniform(values, basicType, components, 1, count,
                  false, shProg, location, uni);
    }
@@ -846,7 +846,7 @@ _mesa_uniform_matrix(struct gl_context *ctx, struct gl_shader_program *shProg,
       }
    }
 
-   if (ctx->_Shader->Flags & GLSL_UNIFORMS) {
+   if (unlikely(ctx->_Shader->Flags & GLSL_UNIFORMS)) {
       log_uniform(values, GLSL_TYPE_FLOAT, components, vectors, count,
                  bool(transpose), shProg, location, uni);
    }