summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/iris/iris_context.h
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2019-05-28 15:34:52 -0700
committerKenneth Graunke <[email protected]>2019-05-29 18:16:32 +0000
commite1409aead589d582f62a2526d2acaf03c704615f (patch)
treed3618de4ab504b7f6893c9652c9c7f18bcf8f58d /src/gallium/drivers/iris/iris_context.h
parente45bf01940fa6692d4f1d9385c2d6466da06a9bb (diff)
iris: Only store the SHA1 of the NIR in iris_uncompiled_shader
Jason pointed out that we don't need to keep an entire copy of the serialized NIR around, we just need the SHA1. This does change our disk cache key to be taking a SHA1 of a SHA1, which is a bit odd, but should work out and be faster and use less memory. Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/gallium/drivers/iris/iris_context.h')
-rw-r--r--src/gallium/drivers/iris/iris_context.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/gallium/drivers/iris/iris_context.h b/src/gallium/drivers/iris/iris_context.h
index fb4423957ca..42cad5e8551 100644
--- a/src/gallium/drivers/iris/iris_context.h
+++ b/src/gallium/drivers/iris/iris_context.h
@@ -260,9 +260,8 @@ struct iris_uncompiled_shader {
struct pipe_stream_output_info stream_output;
- /* The serialized NIR (for the disk cache) and size in bytes. */
- void *ir_cache_binary;
- uint32_t ir_cache_binary_size;
+ /* A SHA1 of the serialized NIR for the disk cache. */
+ unsigned char nir_sha1[20];
unsigned program_id;