| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 0 |
| ; Bound: 72 |
| ; Schema: 0 |
| OpCapability Shader |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint GLCompute %f "f" %local_invocation_index_1 |
| OpExecutionMode %f LocalSize 1 1 1 |
| OpName %local_invocation_index_1 "local_invocation_index_1" |
| OpName %u_block "u_block" |
| OpMemberName %u_block 0 "inner" |
| OpName %S "S" |
| OpMemberName %S 0 "before" |
| OpMemberName %S 1 "m" |
| OpMemberName %S 2 "after" |
| OpName %u "u" |
| OpName %w "w" |
| OpName %f_inner "f_inner" |
| OpName %local_invocation_index "local_invocation_index" |
| OpName %idx "idx" |
| OpName %f "f" |
| OpDecorate %local_invocation_index_1 BuiltIn LocalInvocationIndex |
| OpDecorate %u_block Block |
| OpMemberDecorate %u_block 0 Offset 0 |
| OpMemberDecorate %S 0 Offset 0 |
| OpMemberDecorate %S 1 Offset 16 |
| OpMemberDecorate %S 1 ColMajor |
| OpMemberDecorate %S 1 MatrixStride 16 |
| OpMemberDecorate %S 2 Offset 128 |
| OpDecorate %_arr_S_uint_4 ArrayStride 192 |
| OpDecorate %u NonWritable |
| OpDecorate %u DescriptorSet 0 |
| OpDecorate %u Binding 0 |
| %uint = OpTypeInt 32 0 |
| %_ptr_Input_uint = OpTypePointer Input %uint |
| %local_invocation_index_1 = OpVariable %_ptr_Input_uint Input |
| %int = OpTypeInt 32 1 |
| %float = OpTypeFloat 32 |
| %v3float = OpTypeVector %float 3 |
| %mat4v3float = OpTypeMatrix %v3float 4 |
| %S = OpTypeStruct %int %mat4v3float %int |
| %uint_4 = OpConstant %uint 4 |
| %_arr_S_uint_4 = OpTypeArray %S %uint_4 |
| %u_block = OpTypeStruct %_arr_S_uint_4 |
| %_ptr_Uniform_u_block = OpTypePointer Uniform %u_block |
| %u = OpVariable %_ptr_Uniform_u_block Uniform |
| %_ptr_Workgroup__arr_S_uint_4 = OpTypePointer Workgroup %_arr_S_uint_4 |
| %w = OpVariable %_ptr_Workgroup__arr_S_uint_4 Workgroup |
| %void = OpTypeVoid |
| %16 = OpTypeFunction %void %uint |
| %_ptr_Function_uint = OpTypePointer Function %uint |
| %23 = OpConstantNull %uint |
| %bool = OpTypeBool |
| %_ptr_Workgroup_S = OpTypePointer Workgroup %S |
| %37 = OpConstantNull %S |
| %uint_1 = OpConstant %uint 1 |
| %uint_2 = OpConstant %uint 2 |
| %uint_264 = OpConstant %uint 264 |
| %uint_0 = OpConstant %uint 0 |
| %_ptr_Uniform__arr_S_uint_4 = OpTypePointer Uniform %_arr_S_uint_4 |
| %int_1 = OpConstant %int 1 |
| %int_2 = OpConstant %int 2 |
| %_ptr_Uniform_S = OpTypePointer Uniform %S |
| %int_3 = OpConstant %int 3 |
| %_ptr_Workgroup_mat4v3float = OpTypePointer Workgroup %mat4v3float |
| %_ptr_Uniform_mat4v3float = OpTypePointer Uniform %mat4v3float |
| %60 = OpConstantNull %int |
| %_ptr_Workgroup_v3float = OpTypePointer Workgroup %v3float |
| %_ptr_Uniform_v3float = OpTypePointer Uniform %v3float |
| %67 = OpTypeFunction %void |
| %f_inner = OpFunction %void None %16 |
| %local_invocation_index = OpFunctionParameter %uint |
| %20 = OpLabel |
| %idx = OpVariable %_ptr_Function_uint Function %23 |
| OpStore %idx %local_invocation_index |
| OpBranch %24 |
| %24 = OpLabel |
| OpLoopMerge %25 %26 None |
| OpBranch %27 |
| %27 = OpLabel |
| %29 = OpLoad %uint %idx |
| %30 = OpULessThan %bool %29 %uint_4 |
| %28 = OpLogicalNot %bool %30 |
| OpSelectionMerge %32 None |
| OpBranchConditional %28 %33 %32 |
| %33 = OpLabel |
| OpBranch %25 |
| %32 = OpLabel |
| %34 = OpLoad %uint %idx |
| %36 = OpAccessChain %_ptr_Workgroup_S %w %34 |
| OpStore %36 %37 |
| OpBranch %26 |
| %26 = OpLabel |
| %38 = OpLoad %uint %idx |
| %40 = OpIAdd %uint %38 %uint_1 |
| OpStore %idx %40 |
| OpBranch %24 |
| %25 = OpLabel |
| OpControlBarrier %uint_2 %uint_2 %uint_264 |
| %46 = OpAccessChain %_ptr_Uniform__arr_S_uint_4 %u %uint_0 |
| %47 = OpLoad %_arr_S_uint_4 %46 |
| OpStore %w %47 |
| %49 = OpAccessChain %_ptr_Workgroup_S %w %int_1 |
| %52 = OpAccessChain %_ptr_Uniform_S %u %uint_0 %int_2 |
| %53 = OpLoad %S %52 |
| OpStore %49 %53 |
| %56 = OpAccessChain %_ptr_Workgroup_mat4v3float %w %int_3 %uint_1 |
| %58 = OpAccessChain %_ptr_Uniform_mat4v3float %u %uint_0 %int_2 %uint_1 |
| %59 = OpLoad %mat4v3float %58 |
| OpStore %56 %59 |
| %62 = OpAccessChain %_ptr_Workgroup_v3float %w %int_1 %uint_1 %60 |
| %64 = OpAccessChain %_ptr_Uniform_v3float %u %uint_0 %60 %uint_1 %int_1 |
| %65 = OpLoad %v3float %64 |
| %66 = OpVectorShuffle %v3float %65 %65 2 0 1 |
| OpStore %62 %66 |
| OpReturn |
| OpFunctionEnd |
| %f = OpFunction %void None %67 |
| %69 = OpLabel |
| %71 = OpLoad %uint %local_invocation_index_1 |
| %70 = OpFunctionCall %void %f_inner %71 |
| OpReturn |
| OpFunctionEnd |