| ; SPIR-V | |
| ; Version: 1.3 | |
| ; Generator: Google Tint Compiler; 1 | |
| ; Bound: 58 | |
| ; Schema: 0 | |
| OpCapability Shader | |
| %39 = OpExtInstImport "GLSL.std.450" | |
| OpMemoryModel Logical GLSL450 | |
| OpEntryPoint Fragment %main "main" | |
| OpExecutionMode %main OriginUpperLeft | |
| OpMemberName %v_block_tint_explicit_layout 0 "inner" | |
| OpName %v_block_tint_explicit_layout "v_block_tint_explicit_layout" | |
| OpMemberName %out_block 0 "inner" | |
| OpName %out_block "out_block" | |
| OpName %main "main" | |
| OpName %offset "offset" | |
| OpMemberName %add_carry_result_u32 0 "result" | |
| OpMemberName %add_carry_result_u32 1 "carry" | |
| OpName %add_carry_result_u32 "add_carry_result_u32" | |
| OpDecorate %_runtimearr_uint ArrayStride 4 | |
| OpMemberDecorate %v_block_tint_explicit_layout 0 Offset 0 | |
| OpDecorate %v_block_tint_explicit_layout Block | |
| OpDecorate %1 DescriptorSet 0 | |
| OpDecorate %1 Binding 0 | |
| OpDecorate %1 NonWritable | |
| OpMemberDecorate %out_block 0 Offset 0 | |
| OpDecorate %out_block Block | |
| OpDecorate %6 DescriptorSet 0 | |
| OpDecorate %6 Binding 1 | |
| OpDecorate %6 Coherent | |
| %uint = OpTypeInt 32 0 | |
| %_runtimearr_uint = OpTypeRuntimeArray %uint | |
| %v_block_tint_explicit_layout = OpTypeStruct %_runtimearr_uint | |
| %_ptr_StorageBuffer_v_block_tint_explicit_layout = OpTypePointer StorageBuffer %v_block_tint_explicit_layout | |
| %1 = OpVariable %_ptr_StorageBuffer_v_block_tint_explicit_layout StorageBuffer | |
| %v4uint = OpTypeVector %uint 4 | |
| %out_block = OpTypeStruct %v4uint | |
| %_ptr_StorageBuffer_out_block = OpTypePointer StorageBuffer %out_block | |
| %6 = OpVariable %_ptr_StorageBuffer_out_block StorageBuffer | |
| %void = OpTypeVoid | |
| %12 = OpTypeFunction %void | |
| %offset = OpConstant %uint 16 | |
| %uint_4294967280 = OpConstant %uint 4294967280 | |
| %_ptr_StorageBuffer__runtimearr_uint = OpTypePointer StorageBuffer %_runtimearr_uint | |
| %uint_0 = OpConstant %uint 0 | |
| %uint_4 = OpConstant %uint 4 | |
| %add_carry_result_u32 = OpTypeStruct %uint %uint | |
| %bool = OpTypeBool | |
| %uint_4294967295 = OpConstant %uint 4294967295 | |
| %uint_1 = OpConstant %uint 1 | |
| %_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint | |
| %_ptr_StorageBuffer_v4uint = OpTypePointer StorageBuffer %v4uint | |
| %main = OpFunction %void None %12 | |
| %13 = OpLabel | |
| %15 = OpBitwiseAnd %uint %offset %uint_4294967280 | |
| %17 = OpAccessChain %_ptr_StorageBuffer__runtimearr_uint %1 %uint_0 | |
| %20 = OpArrayLength %uint %1 0 | |
| %21 = OpIMul %uint %20 %uint_4 | |
| %23 = OpIAddCarry %add_carry_result_u32 %15 %offset | |
| %25 = OpCompositeExtract %uint %23 0 | |
| %26 = OpCompositeExtract %uint %23 1 | |
| %27 = OpIEqual %bool %26 %uint_0 | |
| %29 = OpSelect %uint %27 %25 %uint_4294967295 | |
| %31 = OpULessThan %bool %21 %29 | |
| %32 = OpSelect %uint %31 %uint_0 %15 | |
| %33 = OpSelect %uint %31 %offset %offset | |
| %34 = OpIMul %uint %32 %uint_1 | |
| %36 = OpUDiv %uint %33 %offset | |
| %37 = OpISub %uint %36 %uint_1 | |
| %38 = OpExtInst %uint %39 UMin %uint_0 %37 | |
| %40 = OpIMul %uint %38 %offset | |
| %41 = OpIAdd %uint %34 %40 | |
| %42 = OpUDiv %uint %41 %uint_4 | |
| %43 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 %42 | |
| %45 = OpLoad %uint %43 Aligned 16 | |
| %46 = OpIAdd %uint %42 %uint_1 | |
| %47 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 %46 | |
| %48 = OpLoad %uint %47 None | |
| %49 = OpIAdd %uint %46 %uint_1 | |
| %50 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 %49 | |
| %51 = OpLoad %uint %50 None | |
| %52 = OpIAdd %uint %49 %uint_1 | |
| %53 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0 %52 | |
| %54 = OpLoad %uint %53 None | |
| %55 = OpCompositeConstruct %v4uint %45 %48 %51 %54 | |
| %56 = OpAccessChain %_ptr_StorageBuffer_v4uint %6 %uint_0 | |
| OpStore %56 %55 None | |
| OpReturn | |
| OpFunctionEnd |