zink: sync LTO compiles for GPL pipelines on shader free
this avoids invalid access
affects:
KHR-Single-GL46.arrays_of_arrays_gl.InteractionStorageBuffers2
Fixes: 41ffb15de5 ("zink: implement async gfx precompile")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21246>
This commit is contained in:
committed by
Marge Bot
parent
e8b8279b61
commit
16c019142b
@@ -4502,6 +4502,16 @@ zink_shader_free(struct zink_screen *screen, struct zink_shader *shader)
|
||||
simple_mtx_unlock(&prog->ctx->program_lock[idx]);
|
||||
util_queue_fence_wait(&prog->base.cache_fence);
|
||||
|
||||
for (unsigned r = 0; r < ARRAY_SIZE(prog->pipelines); r++) {
|
||||
for (int i = 0; i < ARRAY_SIZE(prog->pipelines[0]); ++i) {
|
||||
hash_table_foreach(&prog->pipelines[r][i], entry) {
|
||||
struct zink_gfx_pipeline_cache_entry *pc_entry = entry->data;
|
||||
|
||||
util_queue_fence_wait(&pc_entry->fence);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
while (util_dynarray_contains(&shader->pipeline_libs, struct zink_gfx_lib_cache*)) {
|
||||
struct zink_gfx_lib_cache *libs = util_dynarray_pop(&shader->pipeline_libs, struct zink_gfx_lib_cache*);
|
||||
if (!libs->removed) {
|
||||
|
||||
Reference in New Issue
Block a user