Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 1 | ; SPIR-V |
| 2 | ; Version: 1.3 |
| 3 | ; Generator: Google Tint Compiler; 0 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 4 | ; Bound: 43 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 5 | ; Schema: 0 |
| 6 | OpCapability Shader |
| 7 | OpMemoryModel Logical GLSL450 |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 8 | OpEntryPoint Vertex %vertex_main "vertex_main" %value %vertex_point_size |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 9 | OpEntryPoint Fragment %fragment_main "fragment_main" |
| 10 | OpEntryPoint GLCompute %compute_main "compute_main" |
| 11 | OpExecutionMode %fragment_main OriginUpperLeft |
| 12 | OpExecutionMode %compute_main LocalSize 1 1 1 |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 13 | OpName %value "value" |
| 14 | OpName %vertex_point_size "vertex_point_size" |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 15 | OpName %SB_RO "SB_RO" |
| 16 | OpMemberName %SB_RO 0 "arg_0" |
| 17 | OpName %sb_ro "sb_ro" |
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 | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 21 | OpName %arrayLength_a0f5ca "arrayLength_a0f5ca" |
| 22 | OpName %res "res" |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 23 | OpName %vertex_main_inner "vertex_main_inner" |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 24 | OpName %vertex_main "vertex_main" |
| 25 | OpName %fragment_main "fragment_main" |
| 26 | OpName %compute_main "compute_main" |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 27 | OpDecorate %value BuiltIn Position |
| 28 | OpDecorate %vertex_point_size BuiltIn PointSize |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 29 | OpDecorate %SB_RO Block |
| 30 | OpMemberDecorate %SB_RO 0 Offset 0 |
| 31 | OpDecorate %_runtimearr_float ArrayStride 4 |
| 32 | OpDecorate %sb_ro NonWritable |
| 33 | OpDecorate %sb_ro DescriptorSet 0 |
| 34 | OpDecorate %sb_ro Binding 1 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 35 | OpDecorate %prevent_dce_block Block |
| 36 | OpMemberDecorate %prevent_dce_block 0 Offset 0 |
| 37 | OpDecorate %prevent_dce DescriptorSet 2 |
| 38 | OpDecorate %prevent_dce Binding 0 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 39 | %float = OpTypeFloat 32 |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 40 | %v4float = OpTypeVector %float 4 |
| 41 | %_ptr_Output_v4float = OpTypePointer Output %v4float |
| 42 | %5 = OpConstantNull %v4float |
| 43 | %value = OpVariable %_ptr_Output_v4float Output %5 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 44 | %_ptr_Output_float = OpTypePointer Output %float |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 45 | %8 = OpConstantNull %float |
| 46 | %vertex_point_size = OpVariable %_ptr_Output_float Output %8 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 47 | %_runtimearr_float = OpTypeRuntimeArray %float |
| 48 | %SB_RO = OpTypeStruct %_runtimearr_float |
| 49 | %_ptr_StorageBuffer_SB_RO = OpTypePointer StorageBuffer %SB_RO |
| 50 | %sb_ro = OpVariable %_ptr_StorageBuffer_SB_RO StorageBuffer |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 51 | %uint = OpTypeInt 32 0 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 52 | %prevent_dce_block = OpTypeStruct %uint |
| 53 | %_ptr_StorageBuffer_prevent_dce_block = OpTypePointer StorageBuffer %prevent_dce_block |
| 54 | %prevent_dce = OpVariable %_ptr_StorageBuffer_prevent_dce_block StorageBuffer |
| 55 | %void = OpTypeVoid |
| 56 | %17 = OpTypeFunction %void |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 57 | %_ptr_Function_uint = OpTypePointer Function %uint |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 58 | %24 = OpConstantNull %uint |
| 59 | %uint_0 = OpConstant %uint 0 |
| 60 | %_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint |
| 61 | %29 = OpTypeFunction %v4float |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 62 | %float_1 = OpConstant %float 1 |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 63 | %arrayLength_a0f5ca = OpFunction %void None %17 |
| 64 | %20 = OpLabel |
| 65 | %res = OpVariable %_ptr_Function_uint Function %24 |
| 66 | %21 = OpArrayLength %uint %sb_ro 0 |
| 67 | OpStore %res %21 |
| 68 | %27 = OpAccessChain %_ptr_StorageBuffer_uint %prevent_dce %uint_0 |
| 69 | %28 = OpLoad %uint %res |
| 70 | OpStore %27 %28 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 71 | OpReturn |
| 72 | OpFunctionEnd |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 73 | %vertex_main_inner = OpFunction %v4float None %29 |
| 74 | %31 = OpLabel |
| 75 | %32 = OpFunctionCall %void %arrayLength_a0f5ca |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 76 | OpReturnValue %5 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 77 | OpFunctionEnd |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 78 | %vertex_main = OpFunction %void None %17 |
| 79 | %34 = OpLabel |
| 80 | %35 = OpFunctionCall %v4float %vertex_main_inner |
| 81 | OpStore %value %35 |
James Price | 11c6fcd | 2021-08-05 17:34:19 +0000 | [diff] [blame] | 82 | OpStore %vertex_point_size %float_1 |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 83 | OpReturn |
| 84 | OpFunctionEnd |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 85 | %fragment_main = OpFunction %void None %17 |
| 86 | %38 = OpLabel |
| 87 | %39 = OpFunctionCall %void %arrayLength_a0f5ca |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 88 | OpReturn |
| 89 | OpFunctionEnd |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 90 | %compute_main = OpFunction %void None %17 |
| 91 | %41 = OpLabel |
| 92 | %42 = OpFunctionCall %void %arrayLength_a0f5ca |
Ben Clayton | 433b4ec | 2021-06-18 18:56:13 +0000 | [diff] [blame] | 93 | OpReturn |
| 94 | OpFunctionEnd |