vkd3d-shader/ir: Validate index count for DEPTHOUT registers.

This commit is contained in:
Giovanni Mascellani 2024-09-26 19:06:18 +02:00 committed by Henri Verbeet
parent 53e35f2d76
commit c3757e6930
Notes: Henri Verbeet 2024-10-02 22:38:04 +02:00
Approved-by: Elizabeth Figura (@zfigura)
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1136

View File

@ -6223,6 +6223,13 @@ static void vsir_validate_register(struct validation_context *ctx,
reg->dimension); reg->dimension);
break; break;
case VKD3DSPR_DEPTHOUT:
if (reg->idx_count != 0)
validator_error(ctx, VKD3D_SHADER_ERROR_VSIR_INVALID_INDEX_COUNT,
"Invalid index count %u for a DEPTHOUT register.",
reg->idx_count);
break;
default: default:
break; break;
} }