blob: 119fd570f08868979bc016bdb46dc51bab9524a5 [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: 63
5; Schema: 0
6 OpCapability Shader
7 OpCapability Float16
8 OpCapability UniformAndStorageBuffer16BitAccess
9 OpCapability StorageBuffer16BitAccess
10 OpCapability StorageInputOutput16
11 %23 = OpExtInstImport "GLSL.std.450"
12 OpMemoryModel Logical GLSL450
13 OpEntryPoint Fragment %fragment_main "fragment_main"
14 OpEntryPoint GLCompute %compute_main "compute_main"
15 OpEntryPoint Vertex %vertex_main "vertex_main" %vertex_main_position_Output %vertex_main_loc0_Output %vertex_main___point_size_Output
16 OpExecutionMode %fragment_main OriginUpperLeft
17 OpExecutionMode %compute_main LocalSize 1 1 1
18 OpMemberName %tint_symbol_1 0 "tint_symbol"
19 OpName %tint_symbol_1 "tint_symbol_1"
20 OpName %vertex_main_position_Output "vertex_main_position_Output"
21 OpName %vertex_main_loc0_Output "vertex_main_loc0_Output"
22 OpName %vertex_main___point_size_Output "vertex_main___point_size_Output"
23 OpName %ldexp_8e43e9 "ldexp_8e43e9"
24 OpName %arg_0 "arg_0"
25 OpName %res "res"
26 OpName %fragment_main "fragment_main"
27 OpName %compute_main "compute_main"
28 OpName %vertex_main_inner "vertex_main_inner"
29 OpMemberName %VertexOutput 0 "pos"
30 OpMemberName %VertexOutput 1 "prevent_dce"
31 OpName %VertexOutput "VertexOutput"
32 OpName %out "out"
33 OpName %vertex_main "vertex_main"
34 OpMemberDecorate %tint_symbol_1 0 Offset 0
35 OpDecorate %tint_symbol_1 Block
36 OpDecorate %1 DescriptorSet 0
37 OpDecorate %1 Binding 0
dan sinclaird117d652024-08-21 01:20:00 +000038 OpDecorate %1 Coherent
dan sinclair1b77b6c2024-08-06 15:47:05 +000039 OpDecorate %vertex_main_position_Output BuiltIn Position
40 OpDecorate %vertex_main_loc0_Output Location 0
41 OpDecorate %vertex_main_loc0_Output Flat
42 OpDecorate %vertex_main___point_size_Output BuiltIn PointSize
43 OpMemberDecorate %VertexOutput 0 Offset 0
44 OpMemberDecorate %VertexOutput 1 Offset 16
45 %half = OpTypeFloat 16
46 %v3half = OpTypeVector %half 3
47%tint_symbol_1 = OpTypeStruct %v3half
48%_ptr_StorageBuffer_tint_symbol_1 = OpTypePointer StorageBuffer %tint_symbol_1
49 %1 = OpVariable %_ptr_StorageBuffer_tint_symbol_1 StorageBuffer
50 %float = OpTypeFloat 32
51 %v4float = OpTypeVector %float 4
52%_ptr_Output_v4float = OpTypePointer Output %v4float
53%vertex_main_position_Output = OpVariable %_ptr_Output_v4float Output
54%_ptr_Output_v3half = OpTypePointer Output %v3half
55%vertex_main_loc0_Output = OpVariable %_ptr_Output_v3half Output
56%_ptr_Output_float = OpTypePointer Output %float
57%vertex_main___point_size_Output = OpVariable %_ptr_Output_float Output
58 %15 = OpTypeFunction %v3half
59%_ptr_Function_v3half = OpTypePointer Function %v3half
60%half_0x1p_0 = OpConstant %half 0x1p+0
61 %19 = OpConstantComposite %v3half %half_0x1p_0 %half_0x1p_0 %half_0x1p_0
62 %int = OpTypeInt 32 1
63 %v3int = OpTypeVector %int 3
64 %int_1 = OpConstant %int 1
65 %24 = OpConstantComposite %v3int %int_1 %int_1 %int_1
66 %void = OpTypeVoid
67 %32 = OpTypeFunction %void
68%_ptr_StorageBuffer_v3half = OpTypePointer StorageBuffer %v3half
69 %uint = OpTypeInt 32 0
70 %uint_0 = OpConstant %uint 0
71%VertexOutput = OpTypeStruct %v4float %v3half
72 %45 = OpTypeFunction %VertexOutput
73%_ptr_Function_VertexOutput = OpTypePointer Function %VertexOutput
74 %49 = OpConstantNull %VertexOutput
75%_ptr_Function_v4float = OpTypePointer Function %v4float
76 %52 = OpConstantNull %v4float
77 %uint_1 = OpConstant %uint 1
78 %float_1 = OpConstant %float 1
79%ldexp_8e43e9 = OpFunction %v3half None %15
80 %16 = OpLabel
81 %arg_0 = OpVariable %_ptr_Function_v3half Function
82 %res = OpVariable %_ptr_Function_v3half Function
83 OpStore %arg_0 %19
dan sinclair50260412024-08-28 19:43:27 +000084 %21 = OpLoad %v3half %arg_0 None
dan sinclair1b77b6c2024-08-06 15:47:05 +000085 %22 = OpExtInst %v3half %23 Ldexp %21 %24
86 OpStore %res %22
dan sinclair50260412024-08-28 19:43:27 +000087 %29 = OpLoad %v3half %res None
dan sinclair1b77b6c2024-08-06 15:47:05 +000088 OpReturnValue %29
89 OpFunctionEnd
90%fragment_main = OpFunction %void None %32
91 %33 = OpLabel
92 %34 = OpFunctionCall %v3half %ldexp_8e43e9
93 %35 = OpAccessChain %_ptr_StorageBuffer_v3half %1 %uint_0
dan sinclair50260412024-08-28 19:43:27 +000094 OpStore %35 %34 None
dan sinclair1b77b6c2024-08-06 15:47:05 +000095 OpReturn
96 OpFunctionEnd
97%compute_main = OpFunction %void None %32
98 %40 = OpLabel
99 %41 = OpFunctionCall %v3half %ldexp_8e43e9
100 %42 = OpAccessChain %_ptr_StorageBuffer_v3half %1 %uint_0
dan sinclair50260412024-08-28 19:43:27 +0000101 OpStore %42 %41 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000102 OpReturn
103 OpFunctionEnd
104%vertex_main_inner = OpFunction %VertexOutput None %45
105 %46 = OpLabel
106 %out = OpVariable %_ptr_Function_VertexOutput Function %49
107 %50 = OpAccessChain %_ptr_Function_v4float %out %uint_0
dan sinclair50260412024-08-28 19:43:27 +0000108 OpStore %50 %52 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000109 %53 = OpAccessChain %_ptr_Function_v3half %out %uint_1
110 %55 = OpFunctionCall %v3half %ldexp_8e43e9
dan sinclair50260412024-08-28 19:43:27 +0000111 OpStore %53 %55 None
112 %56 = OpLoad %VertexOutput %out None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000113 OpReturnValue %56
114 OpFunctionEnd
115%vertex_main = OpFunction %void None %32
116 %58 = OpLabel
117 %59 = OpFunctionCall %VertexOutput %vertex_main_inner
118 %60 = OpCompositeExtract %v4float %59 0
dan sinclair50260412024-08-28 19:43:27 +0000119 OpStore %vertex_main_position_Output %60 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000120 %61 = OpCompositeExtract %v3half %59 1
dan sinclair50260412024-08-28 19:43:27 +0000121 OpStore %vertex_main_loc0_Output %61 None
122 OpStore %vertex_main___point_size_Output %float_1 None
dan sinclair1b77b6c2024-08-06 15:47:05 +0000123 OpReturn
124 OpFunctionEnd