Debian Codegraph @

third_party/spirv-cross/shaders/asm/geom/unroll-glposition-load.asm.geom

raw
1 ; SPIR-V
2 ; Version: 1.0
3 ; Generator: Khronos Glslang Reference Front End; 7
4 ; Bound: 55
5 ; Schema: 0
6 OpCapability Geometry
7 %1 = OpExtInstImport "GLSL.std.450"
8 OpMemoryModel Logical GLSL450
9 OpEntryPoint Geometry %main "main" %OUT_pos %positions_1
10 OpExecutionMode %main Triangles
11 OpExecutionMode %main Invocations 1
12 OpExecutionMode %main OutputTriangleStrip
13 OpExecutionMode %main OutputVertices 3
14 OpSource HLSL 500
15 OpName %main "main"
16 OpName %SceneOut "SceneOut"
17 OpMemberName %SceneOut 0 "pos"
18 OpName %_main_vf4_3__struct_SceneOut_vf41_ "@main(vf4[3];struct-SceneOut-vf41;"
19 OpName %positions "positions"
20 OpName %OUT "OUT"
21 OpName %i "i"
22 OpName %o "o"
23 OpName %OUT_pos "OUT.pos"
24 OpName %positions_0 "positions"
25 OpName %positions_1 "positions"
26 OpName %OUT_0 "OUT"
27 OpName %param "param"
28 OpName %param_0 "param"
29 OpDecorate %OUT_pos BuiltIn Position
30 OpDecorate %positions_1 BuiltIn Position
31 %void = OpTypeVoid
32 %3 = OpTypeFunction %void
33 %float = OpTypeFloat 32
34 %v4float = OpTypeVector %float 4
35 %uint = OpTypeInt 32 0
36 %uint_3 = OpConstant %uint 3
37 %_arr_v4float_uint_3 = OpTypeArray %v4float %uint_3
38 %_ptr_Function__arr_v4float_uint_3 = OpTypePointer Function %_arr_v4float_uint_3
39 %SceneOut = OpTypeStruct %v4float
40 %_ptr_Function_SceneOut = OpTypePointer Function %SceneOut
41 %14 = OpTypeFunction %void %_ptr_Function__arr_v4float_uint_3 %_ptr_Function_SceneOut
42 %int = OpTypeInt 32 1
43 %_ptr_Function_int = OpTypePointer Function %int
44 %int_0 = OpConstant %int 0
45 %int_3 = OpConstant %int 3
46 %bool = OpTypeBool
47 %_ptr_Function_v4float = OpTypePointer Function %v4float
48 %_ptr_Output_v4float = OpTypePointer Output %v4float
49 %OUT_pos = OpVariable %_ptr_Output_v4float Output
50 %int_1 = OpConstant %int 1
51 %_ptr_Input__arr_v4float_uint_3 = OpTypePointer Input %_arr_v4float_uint_3
52 %positions_1 = OpVariable %_ptr_Input__arr_v4float_uint_3 Input
53 %main = OpFunction %void None %3
54 %5 = OpLabel
55 %positions_0 = OpVariable %_ptr_Function__arr_v4float_uint_3 Function
56 %OUT_0 = OpVariable %_ptr_Function_SceneOut Function
57 %param = OpVariable %_ptr_Function__arr_v4float_uint_3 Function
58 %param_0 = OpVariable %_ptr_Function_SceneOut Function
59 %48 = OpLoad %_arr_v4float_uint_3 %positions_1
60 OpStore %positions_0 %48
61 %51 = OpLoad %_arr_v4float_uint_3 %positions_0
62 OpStore %param %51
63 %53 = OpFunctionCall %void %_main_vf4_3__struct_SceneOut_vf41_ %param %param_0
64 %54 = OpLoad %SceneOut %param_0
65 OpStore %OUT_0 %54
66 OpReturn
67 OpFunctionEnd
68 %_main_vf4_3__struct_SceneOut_vf41_ = OpFunction %void None %14
69 %positions = OpFunctionParameter %_ptr_Function__arr_v4float_uint_3
70 %OUT = OpFunctionParameter %_ptr_Function_SceneOut
71 %18 = OpLabel
72 %i = OpVariable %_ptr_Function_int Function
73 %o = OpVariable %_ptr_Function_SceneOut Function
74 OpStore %i %int_0
75 OpBranch %23
76 %23 = OpLabel
77 OpLoopMerge %25 %26 None
78 OpBranch %27
79 %27 = OpLabel
80 %28 = OpLoad %int %i
81 %31 = OpSLessThan %bool %28 %int_3
82 OpBranchConditional %31 %24 %25
83 %24 = OpLabel
84 %33 = OpLoad %int %i
85 %35 = OpAccessChain %_ptr_Function_v4float %positions %33
86 %36 = OpLoad %v4float %35
87 %37 = OpAccessChain %_ptr_Function_v4float %o %int_0
88 OpStore %37 %36
89 %40 = OpAccessChain %_ptr_Function_v4float %o %int_0
90 %41 = OpLoad %v4float %40
91 OpStore %OUT_pos %41
92 OpEmitVertex
93 OpBranch %26
94 %26 = OpLabel
95 %42 = OpLoad %int %i
96 %44 = OpIAdd %int %42 %int_1
97 OpStore %i %44
98 OpBranch %23
99 %25 = OpLabel
100 OpEndPrimitive
101 OpReturn
102 OpFunctionEnd