From 8e186cef2cac8e45a94befe0a30c52d3e56d4d1e Mon Sep 17 00:00:00 2001 From: Kenneth Graunke Date: Sat, 16 Jun 2018 10:15:24 -0700 Subject: [PATCH] iris: rzalloc iris_compiled_shader so memcmp works even if padding creeps in --- src/gallium/drivers/iris/iris_program_cache.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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); -- 2.30.2