From: Kenneth Graunke Date: Sat, 16 Jun 2018 17:15:24 +0000 (-0700) Subject: iris: rzalloc iris_compiled_shader so memcmp works even if padding creeps in X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=8e186cef2cac8e45a94befe0a30c52d3e56d4d1e;p=mesa.git iris: rzalloc iris_compiled_shader so memcmp works even if padding creeps in --- diff --git a/src/gallium/drivers/iris/iris_program_cache.c b/src/gallium/drivers/iris/iris_program_cache.c index 2e9846df732..8a55dc91cc7 100644 --- a/src/gallium/drivers/iris/iris_program_cache.c +++ b/src/gallium/drivers/iris/iris_program_cache.c @@ -215,8 +215,8 @@ iris_upload_shader(struct iris_context *ice, struct gen_device_info *devinfo = &screen->devinfo; struct hash_table *cache = ice->shaders.cache; struct iris_compiled_shader *shader = - ralloc_size(cache, sizeof(struct iris_compiled_shader) + - ice->vtbl.derived_program_state_size(cache_id)); + rzalloc_size(cache, sizeof(struct iris_compiled_shader) + + ice->vtbl.derived_program_state_size(cache_id)); const struct iris_compiled_shader *existing = find_existing_assembly(cache, assembly, prog_data->program_size);