spirv-val: Label VUID 04667 (#4201)
This commit is contained in:
Родитель
a732e4c03c
Коммит
2b0d16a059
|
@ -427,7 +427,8 @@ spv_result_t ValidateTypeStruct(ValidationState_t& _, const Instruction* inst) {
|
|||
if (spvIsVulkanEnv(_.context()->target_env) &&
|
||||
!_.options()->before_hlsl_legalization && ContainsOpaqueType(_, inst)) {
|
||||
return _.diag(SPV_ERROR_INVALID_ID, inst)
|
||||
<< "In " << spvLogStringForEnv(_.context()->target_env)
|
||||
<< _.VkErrorID(4667) << "In "
|
||||
<< spvLogStringForEnv(_.context()->target_env)
|
||||
<< ", OpTypeStruct must not contain an opaque type.";
|
||||
}
|
||||
|
||||
|
|
|
@ -1718,6 +1718,8 @@ std::string ValidationState_t::VkErrorID(uint32_t id,
|
|||
return VUID_WRAP(VUID-StandaloneSpirv-Offset-04663);
|
||||
case 4664:
|
||||
return VUID_WRAP(VUID-StandaloneSpirv-OpImageGather-04664);
|
||||
case 4667:
|
||||
return VUID_WRAP(VUID-StandaloneSpirv-None-04667);
|
||||
case 4669:
|
||||
return VUID_WRAP(VUID-StandaloneSpirv-GLSLShared-04669);
|
||||
case 4675:
|
||||
|
|
|
@ -1055,6 +1055,8 @@ TEST_F(ValidateIdWithMessage, OpTypeStructOpaqueTypeBad) {
|
|||
)";
|
||||
CompileSuccessfully(spirv.c_str(), SPV_ENV_VULKAN_1_0);
|
||||
EXPECT_EQ(SPV_ERROR_INVALID_ID, ValidateInstructions(SPV_ENV_VULKAN_1_0));
|
||||
EXPECT_THAT(getDiagnosticString(),
|
||||
AnyVUID("VUID-StandaloneSpirv-None-04667"));
|
||||
EXPECT_THAT(getDiagnosticString(),
|
||||
HasSubstr("OpTypeStruct must not contain an opaque type"));
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче