blob: ef406acc2c04d657bf9ddd2268bb6166231b1db4 [file] [log] [blame]
Alastair Donaldsonf7e73d42021-07-23 13:10:12 +00001 OpCapability Shader
2 %1 = OpExtInstImport "GLSL.std.450"
3 OpMemoryModel Logical GLSL450
4 OpEntryPoint Fragment %main "main" %_GLF_color
5 OpExecutionMode %main OriginUpperLeft
6 OpSource ESSL 310
7 OpName %main "main"
8 OpName %computeColor_ "computeColor("
9 OpName %_GLF_color "_GLF_color"
10 OpName %_injected_loop_counter "_injected_loop_counter"
11 OpName %buf0 "buf0"
12 OpMemberName %buf0 0 "injectionSwitch"
13 OpName %_ ""
14 OpDecorate %_GLF_color Location 0
15 OpDecorate %_injected_loop_counter RelaxedPrecision
16 OpMemberDecorate %buf0 0 Offset 0
17 OpDecorate %buf0 Block
18 OpDecorate %_ DescriptorSet 0
19 OpDecorate %_ Binding 0
20 %void = OpTypeVoid
21 %9 = OpTypeFunction %void
22 %float = OpTypeFloat 32
23 %v3float = OpTypeVector %float 3
24 %12 = OpTypeFunction %v3float
25 %v4float = OpTypeVector %float 4
26%_ptr_Output_v4float = OpTypePointer Output %v4float
27 %_GLF_color = OpVariable %_ptr_Output_v4float Output
28 %float_1 = OpConstant %float 1
29 %float_0 = OpConstant %float 0
30 %17 = OpConstantComposite %v4float %float_1 %float_0 %float_0 %float_1
31 %int = OpTypeInt 32 1
32%_ptr_Function_int = OpTypePointer Function %int
33 %int_1 = OpConstant %int 1
34 %bool = OpTypeBool
35 %true = OpConstantTrue %bool
36 %v2float = OpTypeVector %float 2
37 %buf0 = OpTypeStruct %v2float
38%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
39 %_ = OpVariable %_ptr_Uniform_buf0 Uniform
40 %int_0 = OpConstant %int 0
41 %uint = OpTypeInt 32 0
42 %uint_0 = OpConstant %uint 0
43%_ptr_Uniform_float = OpTypePointer Uniform %float
44 %29 = OpConstantComposite %v3float %float_1 %float_1 %float_1
45 %main = OpFunction %void None %9
46 %30 = OpLabel
47 %31 = OpFunctionCall %v3float %computeColor_
48 OpReturn
49 OpFunctionEnd
50%computeColor_ = OpFunction %v3float None %12
51 %32 = OpLabel
52%_injected_loop_counter = OpVariable %_ptr_Function_int Function
53 OpStore %_GLF_color %17
54 OpStore %_injected_loop_counter %int_1
55 OpBranch %33
56 %33 = OpLabel
57 OpLoopMerge %34 %35 None
58 OpBranch %36
59 %36 = OpLabel
60 %37 = OpAccessChain %_ptr_Uniform_float %_ %int_0 %uint_0
61 %38 = OpLoad %float %37
62 %39 = OpFOrdGreaterThan %bool %38 %float_1
63 OpSelectionMerge %40 None
64 OpBranchConditional %39 %41 %40
65 %41 = OpLabel
66 %42 = OpAccessChain %_ptr_Uniform_float %_ %int_0 %uint_0
67 %43 = OpLoad %float %42
68 %44 = OpFOrdGreaterThan %bool %43 %float_1
69 OpSelectionMerge %45 None
70 OpBranchConditional %44 %46 %35
71 %46 = OpLabel
72 OpBranch %35
73 %45 = OpLabel
74 OpBranch %35
75 %35 = OpLabel
76 OpBranch %33
77 %40 = OpLabel
78 OpReturnValue %29
79 %34 = OpLabel
80 OpUnreachable
81 OpFunctionEnd