aboutsummaryrefslogtreecommitdiffstats
path: root/src/compiler/glsl/shader_cache.cpp
diff options
context:
space:
mode:
authorEmil Velikov <[email protected]>2017-01-24 21:21:10 +0000
committerEmil Velikov <[email protected]>2017-03-15 11:18:45 +0000
commit0fd61fb639f7704c4faa8c7fd262af32b3a1a01b (patch)
tree94d97f7125e391afa87c47b6eab395b01205dc20 /src/compiler/glsl/shader_cache.cpp
parenta9a4028fd7136ee2ee7bf0efa8179e7a6312f008 (diff)
util/sha1: drop _mesa_sha1_{update, format} return type
Unused/unchecked by any of the callers. v2: Fix the glsl cases that have crept in since v1 Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Grazvydas Ignotas <[email protected]>
Diffstat (limited to 'src/compiler/glsl/shader_cache.cpp')
-rw-r--r--src/compiler/glsl/shader_cache.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/compiler/glsl/shader_cache.cpp b/src/compiler/glsl/shader_cache.cpp
index 7d8d63ba9e7..4b314d59b0e 100644
--- a/src/compiler/glsl/shader_cache.cpp
+++ b/src/compiler/glsl/shader_cache.cpp
@@ -1265,8 +1265,8 @@ shader_cache_write_program_metadata(struct gl_context *ctx,
for (unsigned i = 0; i < prog->NumShaders; i++) {
disk_cache_put_key(cache, prog->Shaders[i]->sha1);
if (ctx->_Shader->Flags & GLSL_CACHE_INFO) {
- fprintf(stderr, "marking shader: %s\n",
- _mesa_sha1_format(sha1_buf, prog->Shaders[i]->sha1));
+ _mesa_sha1_format(sha1_buf, prog->Shaders[i]->sha1);
+ fprintf(stderr, "marking shader: %s\n", sha1_buf);
}
}
@@ -1275,8 +1275,8 @@ shader_cache_write_program_metadata(struct gl_context *ctx,
free(metadata);
if (ctx->_Shader->Flags & GLSL_CACHE_INFO) {
- fprintf(stderr, "putting program metadata in cache: %s\n",
- _mesa_sha1_format(sha1_buf, prog->data->sha1));
+ _mesa_sha1_format(sha1_buf, prog->data->sha1);
+ fprintf(stderr, "putting program metadata in cache: %s\n", sha1_buf);
}
}
@@ -1327,9 +1327,9 @@ shader_cache_read_program_metadata(struct gl_context *ctx,
for (unsigned i = 0; i < prog->NumShaders; i++) {
struct gl_shader *sh = prog->Shaders[i];
+ _mesa_sha1_format(sha1buf, sh->sha1);
ralloc_asprintf_append(&buf, "%s: %s\n",
- _mesa_shader_stage_to_abbrev(sh->Stage),
- _mesa_sha1_format(sha1buf, sh->sha1));
+ _mesa_shader_stage_to_abbrev(sh->Stage), sha1buf);
}
_mesa_sha1_compute(buf, strlen(buf), prog->data->sha1);
ralloc_free(buf);
@@ -1353,8 +1353,9 @@ shader_cache_read_program_metadata(struct gl_context *ctx,
}
if (ctx->_Shader->Flags & GLSL_CACHE_INFO) {
+ _mesa_sha1_format(sha1buf, prog->data->sha1);
fprintf(stderr, "loading shader program meta data from cache: %s\n",
- _mesa_sha1_format(sha1buf, prog->data->sha1));
+ sha1buf);
}
struct blob_reader metadata;