Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sjfricke committed Sep 13, 2022
1 parent 4424b22 commit 9e438a0
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
4 changes: 2 additions & 2 deletions test/val/val_id_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2091,9 +2091,9 @@ TEST_F(ValidateIdWithMessage, OpVariableGood) {
TEST_F(ValidateIdWithMessage, OpVariableInitializerConstantGood) {
std::string spirv = kGLSL450MemoryModel + R"(
%1 = OpTypeInt 32 0
%2 = OpTypePointer Input %1
%2 = OpTypePointer Output %1
%3 = OpConstant %1 42
%4 = OpVariable %2 Input %3)";
%4 = OpVariable %2 Output %3)";
CompileSuccessfully(spirv.c_str());
EXPECT_EQ(SPV_SUCCESS, ValidateInstructions());
}
Expand Down
6 changes: 3 additions & 3 deletions test/val/val_memory_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -506,9 +506,9 @@ TEST_F(ValidateMemory, InitializerWithTaskPayloadWorkgroupEXT) {
%void = OpTypeVoid
%func = OpTypeFunction %void
%uint = OpTypeInt 32 0
%_ptr_TaskPayloadWorkgroupEXT = OpTypePointer TaskPayloadWorkgroupEXT %%uint
%_ptr_TaskPayloadWorkgroupEXT = OpTypePointer TaskPayloadWorkgroupEXT %uint
%uint_1 = OpConstant %uint 1
%payload = OpVariable %_ptr_TaskPayloadWorkgroupEXT Uniform %uint_1
%payload = OpVariable %_ptr_TaskPayloadWorkgroupEXT TaskPayloadWorkgroupEXT %uint_1
%main = OpFunction %void None %func
%label = OpLabel
OpReturn
Expand All @@ -517,7 +517,7 @@ TEST_F(ValidateMemory, InitializerWithTaskPayloadWorkgroupEXT) {
CompileSuccessfully(spirv.c_str(), SPV_ENV_UNIVERSAL_1_5);
EXPECT_EQ(SPV_ERROR_INVALID_ID, ValidateInstructions(SPV_ENV_UNIVERSAL_1_5));
EXPECT_THAT(getDiagnosticString(),
HasSubstr("OpVariable, <id> '5[%5]', initializer are not allowed "
HasSubstr("OpVariable, <id> '2[%2]', initializer are not allowed "
"for TaskPayloadWorkgroupEXT"));
}

Expand Down
4 changes: 0 additions & 4 deletions test/val/val_mesh_shading_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,6 @@ TEST_F(ValidateMeshShading, OpEmitMeshTasksBadGroupCountSignedInt) {
%main = OpFunction %void None %func
%label = OpLabel
OpEmitMeshTasksEXT %int_1 %uint_1 %uint_1
OpReturn
OpFunctionEnd
)";

Expand Down Expand Up @@ -410,7 +409,6 @@ TEST_F(ValidateMeshShading, OpEmitMeshTasksBadGroupCountVector) {
%13 = OpAccessChain %_ptr_uint %x %uint_1
%14 = OpLoad %uint %13
OpEmitMeshTasksEXT %14 %composite %uint_1
OpReturn
OpFunctionEnd
)";

Expand All @@ -437,7 +435,6 @@ TEST_F(ValidateMeshShading, OpEmitMeshTasksBadPayload) {
%main = OpFunction %void None %func
%label = OpLabel
OpEmitMeshTasksEXT %uint_1 %uint_1 %uint_1 %payload
OpReturn
OpFunctionEnd
)";

Expand Down Expand Up @@ -598,7 +595,6 @@ TEST_F(ValidateMeshShading, OpEmitMeshTasksZeroSuccess) {
%main = OpFunction %void None %func
%label = OpLabel
OpEmitMeshTasksEXT %uint_0 %uint_0 %uint_0
OpReturn
OpFunctionEnd
)";

Expand Down

0 comments on commit 9e438a0

Please sign in to comment.