With GPL, we don't necessarily load all stages from the same cache
entry and other stages might have been imported from libraries, so
don't overwrite them.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22264>
}
}
- memcpy(pipeline->shaders, entry->shaders, sizeof(entry->shaders));
+ for (int i = 0; i < MESA_VULKAN_SHADER_STAGES; i++) {
+ if (!entry->shaders[i])
+ continue;
+
+ pipeline->shaders[i] = entry->shaders[i];
+ }
if (pipeline->shaders[MESA_SHADER_GEOMETRY] &&
!pipeline->shaders[MESA_SHADER_GEOMETRY]->info.is_ngg) {