MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-ValidationLayers / TEST_F

Function TEST_F

tests/unit/shader_spirv_positive.cpp:23–50  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21class PositiveShaderSpirv : public VkLayerTest {};
22
23TEST_F(PositiveShaderSpirv, NonSemanticInfo) {
24 // This is a positive test, no errors expected
25 // Verifies the ability to use non-semantic extended instruction sets when the extension is enabled
26 TEST_DESCRIPTION("Create a shader that uses SPV_KHR_non_semantic_info.");
27 AddRequiredExtensions(VK_KHR_SHADER_NON_SEMANTIC_INFO_EXTENSION_NAME);
28 RETURN_IF_SKIP(Init());
29 InitRenderTarget();
30
31 // compute shader using a non-semantic extended instruction set.
32
33 const char* spv_source = R"(
34 OpCapability Shader
35 OpExtension "SPV_KHR_non_semantic_info"
36 %non_semantic = OpExtInstImport "NonSemantic.Validation.Test"
37 OpMemoryModel Logical GLSL450
38 OpEntryPoint GLCompute %main "main"
39 OpExecutionMode %main LocalSize 1 1 1
40 %void = OpTypeVoid
41 %1 = OpExtInst %void %non_semantic 55 %void
42 %func = OpTypeFunction %void
43 %main = OpFunction %void None %func
44 %2 = OpLabel
45 OpReturn
46 OpFunctionEnd
47 )";
48
49 VkShaderObj cs(*m_device, spv_source, VK_SHADER_STAGE_COMPUTE_BIT, SPV_ENV_VULKAN_1_0, SPV_SOURCE_ASM);
50}
51
52TEST_F(PositiveShaderSpirv, GroupDecorations) {
53 TEST_DESCRIPTION("Test shader validation support for group decorations.");

Callers

nothing calls this directly

Calls 15

VkShaderObjClass · 0.85
CmdBindDescriptorSetsFunction · 0.85
CmdBindPipelineFunction · 0.85
CmdDispatchFunction · 0.85
MapMemoryFunction · 0.85
UnmapMemoryFunction · 0.85
CmdDrawFunction · 0.85
c_strMethod · 0.80
CreateComputePipelineMethod · 0.80

Tested by

no test coverage detected