1; SPIR-V 2; Version: 1.0 3; Generator: Khronos SPIR-V Tools Assembler; 0 4; Bound: 32 5; Schema: 0 6 OpCapability Addresses 7 OpCapability Linkage 8 OpCapability Kernel 9 OpMemoryModel Physical32 OpenCL 10 OpEntryPoint Kernel %1 "branch_conditional" %gl_GlobalInvocationID 11 OpName %res "res" 12 OpName %lhs "lhs" 13 OpName %rhs "rhs" 14 OpDecorate %5 FuncParamAttr NoCapture 15 %5 = OpDecorationGroup 16 OpDecorate %gl_GlobalInvocationID BuiltIn GlobalInvocationId 17 OpDecorate %gl_GlobalInvocationID Constant 18 OpDecorate %gl_GlobalInvocationID LinkageAttributes "__spirv_GlobalInvocationId" Import 19 OpGroupDecorate %5 %res %lhs %rhs 20 %uint = OpTypeInt 32 0 21 %v3uint = OpTypeVector %uint 3 22%_ptr_Input_v3uint = OpTypePointer Input %v3uint 23 %bool = OpTypeBool 24 %void = OpTypeVoid 25 %uint_0 = OpConstant %uint 0 26%_ptr_CrossWorkgroup_uint = OpTypePointer CrossWorkgroup %uint 27%_ptr_Function_uint = OpTypePointer Function %uint 28 %15 = OpTypeFunction %void %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint %_ptr_CrossWorkgroup_uint 29%gl_GlobalInvocationID = OpVariable %_ptr_Input_v3uint Input 30 %1 = OpFunction %void None %15 31 %res = OpFunctionParameter %_ptr_CrossWorkgroup_uint 32 %lhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint 33 %rhs = OpFunctionParameter %_ptr_CrossWorkgroup_uint 34 %16 = OpLabel 35 %17 = OpVariable %_ptr_Function_uint Function 36 %18 = OpLoad %v3uint %gl_GlobalInvocationID Aligned 0 37 %19 = OpCompositeExtract %uint %18 0 38 %20 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %lhs %19 39 %21 = OpLoad %uint %20 Aligned 4 40 %22 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %rhs %19 41 %23 = OpLoad %uint %22 Aligned 4 42 %24 = OpSLessThan %bool %21 %23 43 OpBranchConditional %24 %25 %26 44 %25 = OpLabel 45 %27 = OpISub %uint %23 %21 46 OpStore %17 %27 47 OpBranch %28 48 %26 = OpLabel 49 %29 = OpISub %uint %21 %23 50 OpStore %17 %29 51 OpBranch %28 52 %28 = OpLabel 53 %30 = OpLoad %uint %17 54 %31 = OpInBoundsPtrAccessChain %_ptr_CrossWorkgroup_uint %res %19 55 OpStore %31 %30 Aligned 4 56 OpReturn 57 OpFunctionEnd 58