summaryrefslogtreecommitdiffstats
path: root/src/compiler
diff options
context:
space:
mode:
authorTapani Pälli <[email protected]>2018-01-26 11:26:18 +0200
committerTapani Pälli <[email protected]>2018-01-29 08:11:22 +0200
commitd0343bef6680cc660ba691bbed31a2a1b7449f79 (patch)
tree0dcb873d8518aa0f305661121ec6954331bd8475 /src/compiler
parentb99c88037bf64b033579f237ec287857c53b0ad6 (diff)
nir: mark unused space in packed_tex_data
This change cleans following scary warnings in valgrind output when disk cache is being written: ==6532== Uninitialised byte(s) found during client check request ==6532== at 0x14423FAD: blob_write_bytes (blob.c:152) ==6532== by 0x144240FB: blob_write_uint32 (blob.c:194) ==6532== by 0x144001A5: write_tex (nir_serialize.c:613) and later (loads of): ==6532== Use of uninitialised value of size 8 ==6532== at 0x62FCD9E: crc32_z (in /usr/lib64/libz.so.1.2.11) ==6532== by 0x13F65014: util_hash_crc32 (crc32.c:127) ==6532== by 0x13F5DABA: cache_put (disk_cache.c:947) Signed-off-by: Tapani Pälli <[email protected]> Cc: [email protected] Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/nir/nir_serialize.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/compiler/nir/nir_serialize.c b/src/compiler/nir/nir_serialize.c
index 54a00c81d66..9fe46a675f6 100644
--- a/src/compiler/nir/nir_serialize.c
+++ b/src/compiler/nir/nir_serialize.c
@@ -585,6 +585,7 @@ union packed_tex_data {
unsigned component:2;
unsigned has_texture_deref:1;
unsigned has_sampler_deref:1;
+ unsigned unused:10; /* Mark unused for valgrind. */
} u;
};