summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/shaderapi.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2016-11-18 19:49:55 +0100
committerMarek Olšák <[email protected]>2016-11-22 18:05:51 +0100
commitb818df1e714ed8bd2f1c3a68ee842cd81a0d7cf4 (patch)
treeec681ad62ab1b0322c8dab0244b2032fa226d5bf /src/mesa/main/shaderapi.c
parent6dfdf52b6af416fccf28420d64585d809d745b0a (diff)
glsl: add gl_linked_shader::SourceChecksum
for debugging v2: wrap all checksums in #ifdef DEBUG Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/mesa/main/shaderapi.c')
-rw-r--r--src/mesa/main/shaderapi.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 9592857f0f2..83ee0d4ca7d 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -1149,10 +1149,16 @@ print_shader_info(const struct gl_shader_program *shProg)
printf("Mesa: glUseProgram(%u)\n", shProg->Name);
for (i = 0; i < shProg->NumShaders; i++) {
+#ifdef DEBUG
printf(" %s shader %u, checksum %u\n",
_mesa_shader_stage_to_string(shProg->Shaders[i]->Stage),
shProg->Shaders[i]->Name,
shProg->Shaders[i]->SourceChecksum);
+#else
+ printf(" %s shader %u\n",
+ _mesa_shader_stage_to_string(shProg->Shaders[i]->Stage),
+ shProg->Shaders[i]->Name);
+#endif
}
if (shProg->_LinkedShaders[MESA_SHADER_VERTEX])
printf(" vert prog %u\n",