| ; SPIR-V | |
| ; Version: 1.3 | |
| ; Generator: Google Tint Compiler; 0 | |
| ; Bound: 37 | |
| ; Schema: 0 | |
| OpCapability Shader | |
| OpMemoryModel Logical GLSL450 | |
| OpEntryPoint GLCompute %unused_entry_point "unused_entry_point" | |
| OpExecutionMode %unused_entry_point LocalSize 1 1 1 | |
| OpName %unused_entry_point "unused_entry_point" | |
| OpName %f "f" | |
| OpName %i "i" | |
| OpName %j "j" | |
| %void = OpTypeVoid | |
| %1 = OpTypeFunction %void | |
| %int = OpTypeInt 32 1 | |
| %5 = OpTypeFunction %int | |
| %_ptr_Function_int = OpTypePointer Function %int | |
| %11 = OpConstantNull %int | |
| %int_1 = OpConstant %int 1 | |
| %int_4 = OpConstant %int 4 | |
| %bool = OpTypeBool | |
| %int_2 = OpConstant %int 2 | |
| %unused_entry_point = OpFunction %void None %1 | |
| %4 = OpLabel | |
| OpReturn | |
| OpFunctionEnd | |
| %f = OpFunction %int None %5 | |
| %8 = OpLabel | |
| %i = OpVariable %_ptr_Function_int Function %11 | |
| %j = OpVariable %_ptr_Function_int Function %11 | |
| OpBranch %13 | |
| %13 = OpLabel | |
| OpLoopMerge %14 %15 None | |
| OpBranch %16 | |
| %16 = OpLabel | |
| %17 = OpLoad %int %i | |
| %19 = OpIAdd %int %17 %int_1 | |
| OpStore %i %19 | |
| %20 = OpLoad %int %i | |
| %22 = OpSGreaterThan %bool %20 %int_4 | |
| OpSelectionMerge %24 None | |
| OpBranchConditional %22 %25 %24 | |
| %25 = OpLabel | |
| OpReturnValue %int_1 | |
| %24 = OpLabel | |
| OpBranch %26 | |
| %26 = OpLabel | |
| OpLoopMerge %27 %28 None | |
| OpBranch %29 | |
| %29 = OpLabel | |
| %30 = OpLoad %int %j | |
| %31 = OpIAdd %int %30 %int_1 | |
| OpStore %j %31 | |
| %32 = OpLoad %int %j | |
| %33 = OpSGreaterThan %bool %32 %int_4 | |
| OpSelectionMerge %34 None | |
| OpBranchConditional %33 %35 %34 | |
| %35 = OpLabel | |
| OpReturnValue %int_2 | |
| %34 = OpLabel | |
| OpBranch %28 | |
| %28 = OpLabel | |
| OpBranch %26 | |
| %27 = OpLabel | |
| OpBranch %15 | |
| %15 = OpLabel | |
| OpBranch %13 | |
| %14 = OpLabel | |
| OpReturnValue %11 | |
| OpFunctionEnd |