blob: e6480a038ea32de923d5568e5fb47abe126e27c7 [file] [log] [blame]
dan sinclair1b77b6c2024-08-06 15:47:05 +00001; SPIR-V
2; Version: 1.3
3; Generator: Google Tint Compiler; 1
4; Bound: 53
5; Schema: 0
6 OpCapability Shader
7 OpMemoryModel Logical GLSL450
8 OpEntryPoint Fragment %fragment_main "fragment_main"
9 OpEntryPoint GLCompute %compute_main "compute_main"
10 OpEntryPoint Vertex %vertex_main "vertex_main" %vertex_main_position_Output %vertex_main_loc0_Output %vertex_main___point_size_Output
11 OpExecutionMode %fragment_main OriginUpperLeft
12 OpExecutionMode %compute_main LocalSize 1 1 1
13 OpMemberName %tint_symbol_1 0 "tint_symbol"
14 OpName %tint_symbol_1 "tint_symbol_1"
15 OpName %vertex_main_position_Output "vertex_main_position_Output"
16 OpName %vertex_main_loc0_Output "vertex_main_loc0_Output"
17 OpName %vertex_main___point_size_Output "vertex_main___point_size_Output"
18 OpName %clamp_867397 "clamp_867397"
19 OpName %res "res"
20 OpName %fragment_main "fragment_main"
21 OpName %compute_main "compute_main"
22 OpName %vertex_main_inner "vertex_main_inner"
23 OpMemberName %VertexOutput 0 "pos"
24 OpMemberName %VertexOutput 1 "prevent_dce"
25 OpName %VertexOutput "VertexOutput"
26 OpName %out "out"
27 OpName %vertex_main "vertex_main"
28 OpMemberDecorate %tint_symbol_1 0 Offset 0
29 OpDecorate %tint_symbol_1 Block
30 OpDecorate %1 DescriptorSet 0
31 OpDecorate %1 Binding 0
dan sinclaird117d652024-08-21 01:20:00 +000032 OpDecorate %1 Coherent
dan sinclair1b77b6c2024-08-06 15:47:05 +000033 OpDecorate %vertex_main_position_Output BuiltIn Position
34 OpDecorate %vertex_main_loc0_Output Location 0
35 OpDecorate %vertex_main_loc0_Output Flat
36 OpDecorate %vertex_main___point_size_Output BuiltIn PointSize
37 OpMemberDecorate %VertexOutput 0 Offset 0
38 OpMemberDecorate %VertexOutput 1 Offset 16
39 %float = OpTypeFloat 32
40 %v3float = OpTypeVector %float 3
41%tint_symbol_1 = OpTypeStruct %v3float
42%_ptr_StorageBuffer_tint_symbol_1 = OpTypePointer StorageBuffer %tint_symbol_1
43 %1 = OpVariable %_ptr_StorageBuffer_tint_symbol_1 StorageBuffer
44 %v4float = OpTypeVector %float 4
45%_ptr_Output_v4float = OpTypePointer Output %v4float
46%vertex_main_position_Output = OpVariable %_ptr_Output_v4float Output
47%_ptr_Output_v3float = OpTypePointer Output %v3float
48%vertex_main_loc0_Output = OpVariable %_ptr_Output_v3float Output
49%_ptr_Output_float = OpTypePointer Output %float
50%vertex_main___point_size_Output = OpVariable %_ptr_Output_float Output
51 %14 = OpTypeFunction %v3float
52%_ptr_Function_v3float = OpTypePointer Function %v3float
53 %float_1 = OpConstant %float 1
54 %18 = OpConstantComposite %v3float %float_1 %float_1 %float_1
55 %void = OpTypeVoid
56 %23 = OpTypeFunction %void
57%_ptr_StorageBuffer_v3float = OpTypePointer StorageBuffer %v3float
58 %uint = OpTypeInt 32 0
59 %uint_0 = OpConstant %uint 0
60%VertexOutput = OpTypeStruct %v4float %v3float
61 %36 = OpTypeFunction %VertexOutput
62%_ptr_Function_VertexOutput = OpTypePointer Function %VertexOutput
63 %40 = OpConstantNull %VertexOutput
64%_ptr_Function_v4float = OpTypePointer Function %v4float
65 %43 = OpConstantNull %v4float
66 %uint_1 = OpConstant %uint 1
67%clamp_867397 = OpFunction %v3float None %14
68 %15 = OpLabel
69 %res = OpVariable %_ptr_Function_v3float Function
70 OpStore %res %18
dan sinclair50260412024-08-28 19:43:27 +000071 %20 = OpLoad %v3float %res None
dan sinclair1b77b6c2024-08-06 15:47:05 +000072 OpReturnValue %20
73 OpFunctionEnd
74%fragment_main = OpFunction %void None %23
75 %24 = OpLabel
76 %25 = OpFunctionCall %v3float %clamp_867397
77 %26 = OpAccessChain %_ptr_StorageBuffer_v3float %1 %uint_0
dan sinclair50260412024-08-28 19:43:27 +000078 OpStore %26 %25 None
dan sinclair1b77b6c2024-08-06 15:47:05 +000079 OpReturn
80 OpFunctionEnd
81%compute_main = OpFunction %void None %23
82 %31 = OpLabel
83 %32 = OpFunctionCall %v3float %clamp_867397
84 %33 = OpAccessChain %_ptr_StorageBuffer_v3float %1 %uint_0
dan sinclair50260412024-08-28 19:43:27 +000085 OpStore %33 %32 None
dan sinclair1b77b6c2024-08-06 15:47:05 +000086 OpReturn
87 OpFunctionEnd
88%vertex_main_inner = OpFunction %VertexOutput None %36
89 %37 = OpLabel
90 %out = OpVariable %_ptr_Function_VertexOutput Function %40
91 %41 = OpAccessChain %_ptr_Function_v4float %out %uint_0
dan sinclair50260412024-08-28 19:43:27 +000092 OpStore %41 %43 None
dan sinclair1b77b6c2024-08-06 15:47:05 +000093 %44 = OpAccessChain %_ptr_Function_v3float %out %uint_1
94 %46 = OpFunctionCall %v3float %clamp_867397
dan sinclair50260412024-08-28 19:43:27 +000095 OpStore %44 %46 None
96 %47 = OpLoad %VertexOutput %out None
dan sinclair1b77b6c2024-08-06 15:47:05 +000097 OpReturnValue %47
98 OpFunctionEnd
99%vertex_main = OpFunction %void None %23
100 %49 = OpLabel
101 %50 = OpFunctionCall %VertexOutput %vertex_main_inner
102 %51 = OpCompositeExtract %v4float %50 0
dan sinclair50260412024-08-28 19:43:27 +0000103 OpStore %vertex_main_position_Output %51 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000104 %52 = OpCompositeExtract %v3float %50 1
dan sinclair50260412024-08-28 19:43:27 +0000105 OpStore %vertex_main_loc0_Output %52 None
106 OpStore %vertex_main___point_size_Output %float_1 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000107 OpReturn
108 OpFunctionEnd