Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 1 | ; SPIR-V |
| 2 | ; Version: 1.3 |
| 3 | ; Generator: Google Tint Compiler; 0 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 4 | ; Bound: 60 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 5 | ; Schema: 0 |
| 6 | OpCapability Shader |
| 7 | OpCapability ImageQuery |
| 8 | OpMemoryModel Logical GLSL450 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 9 | OpEntryPoint Fragment %fragment_main "fragment_main" |
| 10 | OpEntryPoint GLCompute %compute_main "compute_main" |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 11 | OpEntryPoint Vertex %vertex_main "vertex_main" %pos_1 %prevent_dce_1 %vertex_point_size |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 12 | OpExecutionMode %fragment_main OriginUpperLeft |
| 13 | OpExecutionMode %compute_main LocalSize 1 1 1 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 14 | OpName %pos_1 "pos_1" |
| 15 | OpName %prevent_dce_1 "prevent_dce_1" |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 16 | OpName %vertex_point_size "vertex_point_size" |
| 17 | OpName %arg_0 "arg_0" |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 18 | OpName %prevent_dce_block "prevent_dce_block" |
| 19 | OpMemberName %prevent_dce_block 0 "inner" |
| 20 | OpName %prevent_dce "prevent_dce" |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 21 | OpName %textureNumLayers_d75a0b "textureNumLayers_d75a0b" |
| 22 | OpName %res "res" |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 23 | OpName %fragment_main "fragment_main" |
| 24 | OpName %compute_main "compute_main" |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 25 | OpName %VertexOutput "VertexOutput" |
| 26 | OpMemberName %VertexOutput 0 "pos" |
| 27 | OpMemberName %VertexOutput 1 "prevent_dce" |
| 28 | OpName %vertex_main_inner "vertex_main_inner" |
| 29 | OpName %out "out" |
| 30 | OpName %vertex_main "vertex_main" |
| 31 | OpDecorate %pos_1 BuiltIn Position |
| 32 | OpDecorate %prevent_dce_1 Location 0 |
| 33 | OpDecorate %prevent_dce_1 Flat |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 34 | OpDecorate %vertex_point_size BuiltIn PointSize |
| 35 | OpDecorate %arg_0 NonReadable |
| 36 | OpDecorate %arg_0 DescriptorSet 1 |
| 37 | OpDecorate %arg_0 Binding 0 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 38 | OpDecorate %prevent_dce_block Block |
| 39 | OpMemberDecorate %prevent_dce_block 0 Offset 0 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 40 | OpDecorate %prevent_dce DescriptorSet 0 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 41 | OpDecorate %prevent_dce Binding 0 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 42 | OpMemberDecorate %VertexOutput 0 Offset 0 |
| 43 | OpMemberDecorate %VertexOutput 1 Offset 16 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 44 | %float = OpTypeFloat 32 |
| 45 | %v4float = OpTypeVector %float 4 |
| 46 | %_ptr_Output_v4float = OpTypePointer Output %v4float |
| 47 | %5 = OpConstantNull %v4float |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 48 | %pos_1 = OpVariable %_ptr_Output_v4float Output %5 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 49 | %uint = OpTypeInt 32 0 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 50 | %_ptr_Output_uint = OpTypePointer Output %uint |
| 51 | %9 = OpConstantNull %uint |
| 52 | %prevent_dce_1 = OpVariable %_ptr_Output_uint Output %9 |
| 53 | %_ptr_Output_float = OpTypePointer Output %float |
| 54 | %12 = OpConstantNull %float |
| 55 | %vertex_point_size = OpVariable %_ptr_Output_float Output %12 |
| 56 | %15 = OpTypeImage %float 2D 0 1 0 2 Rgba32f |
| 57 | %_ptr_UniformConstant_15 = OpTypePointer UniformConstant %15 |
| 58 | %arg_0 = OpVariable %_ptr_UniformConstant_15 UniformConstant |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 59 | %prevent_dce_block = OpTypeStruct %uint |
| 60 | %_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block |
| 61 | %prevent_dce = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 62 | %19 = OpTypeFunction %uint |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 63 | %v3uint = OpTypeVector %uint 3 |
| 64 | %_ptr_Function_uint = OpTypePointer Function %uint |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 65 | %void = OpTypeVoid |
| 66 | %29 = OpTypeFunction %void |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 67 | %uint_0 = OpConstant %uint 0 |
| 68 | %_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 69 | %VertexOutput = OpTypeStruct %v4float %uint |
| 70 | %41 = OpTypeFunction %VertexOutput |
| 71 | %_ptr_Function_VertexOutput = OpTypePointer Function %VertexOutput |
| 72 | %47 = OpConstantNull %VertexOutput |
| 73 | %_ptr_Function_v4float = OpTypePointer Function %v4float |
| 74 | %uint_1 = OpConstant %uint 1 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 75 | %float_1 = OpConstant %float 1 |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 76 | %textureNumLayers_d75a0b = OpFunction %uint None %19 |
| 77 | %21 = OpLabel |
| 78 | %res = OpVariable %_ptr_Function_uint Function %9 |
| 79 | %25 = OpLoad %15 %arg_0 |
| 80 | %23 = OpImageQuerySize %v3uint %25 |
| 81 | %22 = OpCompositeExtract %uint %23 2 |
| 82 | OpStore %res %22 |
| 83 | %28 = OpLoad %uint %res |
| 84 | OpReturnValue %28 |
| 85 | OpFunctionEnd |
| 86 | %fragment_main = OpFunction %void None %29 |
| 87 | %32 = OpLabel |
| 88 | %35 = OpAccessChain %_ptr_StorageBuffer_uint %prevent_dce %uint_0 |
| 89 | %36 = OpFunctionCall %uint %textureNumLayers_d75a0b |
| 90 | OpStore %35 %36 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 91 | OpReturn |
| 92 | OpFunctionEnd |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 93 | %compute_main = OpFunction %void None %29 |
| 94 | %38 = OpLabel |
| 95 | %39 = OpAccessChain %_ptr_StorageBuffer_uint %prevent_dce %uint_0 |
| 96 | %40 = OpFunctionCall %uint %textureNumLayers_d75a0b |
| 97 | OpStore %39 %40 |
| 98 | OpReturn |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 99 | OpFunctionEnd |
Natalie Chouinard | e902718 | 2024-06-13 18:50:19 +0000 | [diff] [blame] | 100 | %vertex_main_inner = OpFunction %VertexOutput None %41 |
| 101 | %44 = OpLabel |
| 102 | %out = OpVariable %_ptr_Function_VertexOutput Function %47 |
| 103 | %49 = OpAccessChain %_ptr_Function_v4float %out %uint_0 |
| 104 | OpStore %49 %5 |
| 105 | %51 = OpAccessChain %_ptr_Function_uint %out %uint_1 |
| 106 | %52 = OpFunctionCall %uint %textureNumLayers_d75a0b |
| 107 | OpStore %51 %52 |
| 108 | %53 = OpLoad %VertexOutput %out |
| 109 | OpReturnValue %53 |
| 110 | OpFunctionEnd |
| 111 | %vertex_main = OpFunction %void None %29 |
| 112 | %55 = OpLabel |
| 113 | %56 = OpFunctionCall %VertexOutput %vertex_main_inner |
| 114 | %57 = OpCompositeExtract %v4float %56 0 |
| 115 | OpStore %pos_1 %57 |
| 116 | %58 = OpCompositeExtract %uint %56 1 |
| 117 | OpStore %prevent_dce_1 %58 |
Ben Clayton | 13f0890 | 2022-10-26 18:36:44 +0000 | [diff] [blame] | 118 | OpStore %vertex_point_size %float_1 |
| 119 | OpReturn |
| 120 | OpFunctionEnd |