mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-02-10 22:40:27 +01:00
vulkan/runtime: Account for pipeline libraries stage count
Don't excludes stages coming from pipeline libraries. This caused valid
group indices referring to library stages to be dropped, leading to
mismatched stage_count.
Fixes: e05a9b77b6 ("vulkan/runtime: split rt shaders hashing from compile")
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38669>
This commit is contained in:
parent
e47be4f37b
commit
d8447fd392
1 changed files with 6 additions and 6 deletions
|
|
@ -3023,23 +3023,23 @@ vk_get_rt_pipeline_compile_info(struct vk_rt_pipeline_compile_info *info,
|
|||
group->stage_count = 0;
|
||||
switch (group_info->type) {
|
||||
case VK_RAY_TRACING_SHADER_GROUP_TYPE_GENERAL_KHR:
|
||||
assert(group_info->generalShader < pCreateInfo->stageCount);
|
||||
assert(group_info->generalShader < info->stage_count);
|
||||
group->stage_indices[group->stage_count++] = group_info->generalShader;
|
||||
break;
|
||||
|
||||
case VK_RAY_TRACING_SHADER_GROUP_TYPE_TRIANGLES_HIT_GROUP_KHR:
|
||||
if (group_info->anyHitShader < pCreateInfo->stageCount)
|
||||
if (group_info->anyHitShader < info->stage_count)
|
||||
group->stage_indices[group->stage_count++] = group_info->anyHitShader;
|
||||
if (group_info->closestHitShader < pCreateInfo->stageCount)
|
||||
if (group_info->closestHitShader < info->stage_count)
|
||||
group->stage_indices[group->stage_count++] = group_info->closestHitShader;
|
||||
break;
|
||||
|
||||
case VK_RAY_TRACING_SHADER_GROUP_TYPE_PROCEDURAL_HIT_GROUP_KHR:
|
||||
if (group_info->closestHitShader < pCreateInfo->stageCount)
|
||||
if (group_info->closestHitShader < info->stage_count)
|
||||
group->stage_indices[group->stage_count++] = group_info->closestHitShader;
|
||||
if (group_info->anyHitShader < pCreateInfo->stageCount)
|
||||
if (group_info->anyHitShader < info->stage_count)
|
||||
group->stage_indices[group->stage_count++] = group_info->anyHitShader;
|
||||
assert(group_info->intersectionShader < pCreateInfo->stageCount);
|
||||
assert(group_info->intersectionShader < info->stage_count);
|
||||
group->stage_indices[group->stage_count++] = group_info->intersectionShader;
|
||||
break;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue