| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 1 |
| ; Bound: 28 |
| ; Schema: 0 |
| OpCapability Shader |
| OpCapability Int64 |
| OpCapability Int64Atomics |
| %21 = OpExtInstImport "GLSL.std.450" |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint Fragment %main "main" |
| OpExecutionMode %main OriginUpperLeft |
| OpMemberName %a_block_tint_explicit_layout 0 "inner" |
| OpName %a_block_tint_explicit_layout "a_block_tint_explicit_layout" |
| OpName %main "main" |
| OpDecorate %_runtimearr_ulong ArrayStride 8 |
| OpMemberDecorate %a_block_tint_explicit_layout 0 Offset 0 |
| OpDecorate %a_block_tint_explicit_layout Block |
| OpDecorate %1 DescriptorSet 0 |
| OpDecorate %1 Binding 0 |
| OpDecorate %1 Coherent |
| %ulong = OpTypeInt 64 0 |
| %_runtimearr_ulong = OpTypeRuntimeArray %ulong |
| %a_block_tint_explicit_layout = OpTypeStruct %_runtimearr_ulong |
| %_ptr_StorageBuffer_a_block_tint_explicit_layout = OpTypePointer StorageBuffer %a_block_tint_explicit_layout |
| %1 = OpVariable %_ptr_StorageBuffer_a_block_tint_explicit_layout StorageBuffer |
| %void = OpTypeVoid |
| %8 = OpTypeFunction %void |
| %_ptr_StorageBuffer__runtimearr_ulong = OpTypePointer StorageBuffer %_runtimearr_ulong |
| %uint = OpTypeInt 32 0 |
| %uint_0 = OpConstant %uint 0 |
| %uint_1 = OpConstant %uint 1 |
| %int = OpTypeInt 32 1 |
| %int_0 = OpConstant %int 0 |
| %_ptr_StorageBuffer_ulong = OpTypePointer StorageBuffer %ulong |
| %v2uint = OpTypeVector %uint 2 |
| %25 = OpConstantNull %v2uint |
| %main = OpFunction %void None %8 |
| %9 = OpLabel |
| %10 = OpAccessChain %_ptr_StorageBuffer__runtimearr_ulong %1 %uint_0 |
| %14 = OpArrayLength %uint %1 0 |
| %15 = OpISub %uint %14 %uint_1 |
| %17 = OpBitcast %uint %int_0 |
| %20 = OpExtInst %uint %21 UMin %17 %15 |
| %22 = OpAccessChain %_ptr_StorageBuffer_ulong %1 %uint_0 %20 |
| %24 = OpBitcast %ulong %25 |
| %27 = OpAtomicUMax %ulong %22 %uint_1 %uint_0 %24 |
| OpReturn |
| OpFunctionEnd |