Debian Codegraph @

third_party/spirv-cross/shaders-no-opt/asm/frag/selection-merge-to-continue.asm.invalid.frag

raw
1 ; SPIR-V
2 ; Version: 1.0
3 ; Generator: Khronos Glslang Reference Front End; 3
4 ; Bound: 55
5 ; Schema: 0
6 OpCapability Shader
7 %1 = OpExtInstImport "GLSL.std.450"
8 OpMemoryModel Logical GLSL450
9 OpEntryPoint Fragment %main "main" %FragColor %v0
10 OpExecutionMode %main OriginUpperLeft
11 OpSource GLSL 450
12 OpName %main "main"
13 OpName %FragColor "FragColor"
14 OpName %i "i"
15 OpName %v0 "v0"
16 OpDecorate %FragColor Location 0
17 OpDecorate %v0 Location 0
18 %void = OpTypeVoid
19 %3 = OpTypeFunction %void
20 %float = OpTypeFloat 32
21 %v4float = OpTypeVector %float 4
22 %_ptr_Output_v4float = OpTypePointer Output %v4float
23 %FragColor = OpVariable %_ptr_Output_v4float Output
24 %float_1 = OpConstant %float 1
25 %11 = OpConstantComposite %v4float %float_1 %float_1 %float_1 %float_1
26 %int = OpTypeInt 32 1
27 %_ptr_Function_int = OpTypePointer Function %int
28 %int_0 = OpConstant %int 0
29 %int_4 = OpConstant %int 4
30 %bool = OpTypeBool
31 %_ptr_Input_v4float = OpTypePointer Input %v4float
32 %v0 = OpVariable %_ptr_Input_v4float Input
33 %uint = OpTypeInt 32 0
34 %uint_0 = OpConstant %uint 0
35 %_ptr_Input_float = OpTypePointer Input %float
36 %float_20 = OpConstant %float 20
37 %int_3 = OpConstant %int 3
38 %int_1 = OpConstant %int 1
39 %main = OpFunction %void None %3
40 %5 = OpLabel
41 %i = OpVariable %_ptr_Function_int Function
42 OpStore %FragColor %11
43 OpStore %i %int_0
44 OpBranch %16
45 %16 = OpLabel
46 OpLoopMerge %18 %19 None
47 OpBranch %20
48 %20 = OpLabel
49 %21 = OpLoad %int %i
50 %24 = OpSLessThan %bool %21 %int_4
51 OpBranchConditional %24 %17 %18
52 %17 = OpLabel
53 %30 = OpAccessChain %_ptr_Input_float %v0 %uint_0
54 %31 = OpLoad %float %30
55 %33 = OpFOrdEqual %bool %31 %float_20
56 OpSelectionMerge %19 None
57 OpBranchConditional %33 %34 %44
58 %34 = OpLabel
59 %36 = OpLoad %int %i
60 %38 = OpBitwiseAnd %int %36 %int_3
61 %39 = OpAccessChain %_ptr_Input_float %v0 %38
62 %40 = OpLoad %float %39
63 %41 = OpLoad %v4float %FragColor
64 %42 = OpCompositeConstruct %v4float %40 %40 %40 %40
65 %43 = OpFAdd %v4float %41 %42
66 OpStore %FragColor %43
67 OpBranch %19
68 %44 = OpLabel
69 %45 = OpLoad %int %i
70 %47 = OpBitwiseAnd %int %45 %int_1
71 %48 = OpAccessChain %_ptr_Input_float %v0 %47
72 %49 = OpLoad %float %48
73 %50 = OpLoad %v4float %FragColor
74 %51 = OpCompositeConstruct %v4float %49 %49 %49 %49
75 %52 = OpFAdd %v4float %50 %51
76 OpStore %FragColor %52
77 OpBranch %19
78 %19 = OpLabel
79 %53 = OpLoad %int %i
80 %54 = OpIAdd %int %53 %int_1
81 OpStore %i %54
82 OpBranch %16
83 %18 = OpLabel
84 OpReturn
85 OpFunctionEnd