Files
wgpu/tests/out/spv/control-flow.spvasm
T

138 lines
2.5 KiB
Plaintext

; SPIR-V
; Version: 1.1
; Generator: rspirv
; Bound: 69
OpCapability Shader
%1 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %44 "main" %41
OpExecutionMode %44 LocalSize 1 1 1
OpDecorate %41 BuiltIn GlobalInvocationId
%2 = OpTypeVoid
%4 = OpTypeInt 32 1
%3 = OpConstant %4 1
%5 = OpConstant %4 0
%6 = OpConstant %4 2
%7 = OpConstant %4 3
%8 = OpConstant %4 4
%10 = OpTypeInt 32 0
%9 = OpConstant %10 0
%11 = OpTypeVector %10 3
%15 = OpTypeFunction %2 %4
%21 = OpTypeFunction %2
%38 = OpTypePointer Function %4
%39 = OpConstantNull %4
%42 = OpTypePointer Input %11
%41 = OpVariable %42 Input
%46 = OpConstant %10 2
%47 = OpConstant %10 1
%48 = OpConstant %10 72
%49 = OpConstant %10 264
%14 = OpFunction %2 None %15
%13 = OpFunctionParameter %4
%12 = OpLabel
OpBranch %16
%16 = OpLabel
OpSelectionMerge %17 None
OpSwitch %13 %18
%18 = OpLabel
OpBranch %17
%17 = OpLabel
OpReturn
OpFunctionEnd
%20 = OpFunction %2 None %21
%19 = OpLabel
OpBranch %22
%22 = OpLabel
OpSelectionMerge %23 None
OpSwitch %5 %25 0 %24
%24 = OpLabel
OpBranch %23
%25 = OpLabel
OpBranch %23
%23 = OpLabel
OpReturn
OpFunctionEnd
%28 = OpFunction %2 None %15
%27 = OpFunctionParameter %4
%26 = OpLabel
OpBranch %29
%29 = OpLabel
OpBranch %30
%30 = OpLabel
OpLoopMerge %31 %33 None
OpBranch %32
%32 = OpLabel
OpSelectionMerge %34 None
OpSwitch %27 %36 1 %35
%35 = OpLabel
OpBranch %33
%36 = OpLabel
OpBranch %34
%34 = OpLabel
OpBranch %33
%33 = OpLabel
OpBranch %30
%31 = OpLabel
OpReturn
OpFunctionEnd
%44 = OpFunction %2 None %21
%40 = OpLabel
%37 = OpVariable %38 Function %39
%43 = OpLoad %11 %41
OpBranch %45
%45 = OpLabel
OpControlBarrier %46 %47 %48
OpControlBarrier %46 %46 %49
OpSelectionMerge %50 None
OpSwitch %3 %51
%51 = OpLabel
OpStore %37 %3
OpBranch %50
%50 = OpLabel
%52 = OpLoad %4 %37
OpSelectionMerge %53 None
OpSwitch %52 %58 1 %54 2 %55 3 %56 4 %56 5 %57 6 %58
%54 = OpLabel
OpStore %37 %5
OpBranch %53
%55 = OpLabel
OpStore %37 %3
OpBranch %53
%56 = OpLabel
OpStore %37 %6
OpBranch %53
%57 = OpLabel
OpStore %37 %7
OpBranch %53
%58 = OpLabel
OpStore %37 %8
OpBranch %53
%53 = OpLabel
OpSelectionMerge %59 None
OpSwitch %9 %61 0 %60
%60 = OpLabel
OpBranch %59
%61 = OpLabel
OpBranch %59
%59 = OpLabel
%62 = OpLoad %4 %37
OpSelectionMerge %63 None
OpSwitch %62 %68 1 %64 2 %65 3 %66 4 %67
%64 = OpLabel
OpStore %37 %5
OpBranch %63
%65 = OpLabel
OpStore %37 %3
OpReturn
%66 = OpLabel
OpStore %37 %6
OpReturn
%67 = OpLabel
OpReturn
%68 = OpLabel
OpStore %37 %7
OpReturn
%63 = OpLabel
OpReturn
OpFunctionEnd