[Mesa-dev] [PATCH 45/68] glsl: cache system values read bitfield

Timothy Arceri timothy.arceri at collabora.com
Wed Jun 1 06:23:26 UTC 2016


---
 src/compiler/glsl/shader_cache.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/compiler/glsl/shader_cache.cpp b/src/compiler/glsl/shader_cache.cpp
index 285c600..9ee461e 100644
--- a/src/compiler/glsl/shader_cache.cpp
+++ b/src/compiler/glsl/shader_cache.cpp
@@ -921,6 +921,7 @@ write_shader_metadata(struct blob *metadata, gl_shader *shader)
       /* Use the lowest bit to indicate that there is shader_metadata here. */
       blob_write_uint64(metadata, glprog->InputsRead << 1 | 1);
       blob_write_uint64(metadata, glprog->OutputsWritten);
+      blob_write_uint32(metadata, glprog->SystemValuesRead);
       blob_write_bytes(metadata, glprog->TexturesUsed,
                        sizeof(glprog->TexturesUsed));
       blob_write_bytes(metadata, glprog->SamplerUnits,
@@ -966,6 +967,7 @@ read_shader_metadata(struct blob_reader *metadata,
    if (has_shader) {
       glprog->InputsRead = has_shader >> 1;
       glprog->OutputsWritten = blob_read_uint64(metadata);
+      glprog->SystemValuesRead = blob_read_uint32(metadata);
       blob_copy_bytes(metadata, (uint8_t *) glprog->TexturesUsed,
                       sizeof(glprog->TexturesUsed));
       blob_copy_bytes(metadata, (uint8_t *) glprog->SamplerUnits,
-- 
2.5.5



More information about the mesa-dev mailing list