blob: f75294515d5c76b3a0350734ae5ec0649d43690b [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 159
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %f "f"
OpExecutionMode %f LocalSize 1 1 1
OpName %a_block "a_block"
OpMemberName %a_block 0 "inner"
OpName %Outer_std140 "Outer_std140"
OpMemberName %Outer_std140 0 "a"
OpName %Inner_std140 "Inner_std140"
OpMemberName %Inner_std140 0 "m_0"
OpMemberName %Inner_std140 1 "m_1"
OpMemberName %Inner_std140 2 "m_2"
OpMemberName %Inner_std140 3 "m_3"
OpName %a "a"
OpName %Inner "Inner"
OpMemberName %Inner 0 "m"
OpName %conv_Inner "conv_Inner"
OpName %val "val"
OpName %conv_arr_4_Inner "conv_arr_4_Inner"
OpName %val_0 "val"
OpName %arr "arr"
OpName %i "i"
OpName %var_for_index "var_for_index"
OpName %Outer "Outer"
OpMemberName %Outer 0 "a"
OpName %conv_Outer "conv_Outer"
OpName %val_1 "val"
OpName %conv_arr_4_Outer "conv_arr_4_Outer"
OpName %val_2 "val"
OpName %arr_0 "arr"
OpName %i_0 "i"
OpName %var_for_index_1 "var_for_index_1"
OpName %load_a_3_a_2_m "load_a_3_a_2_m"
OpName %f "f"
OpDecorate %a_block Block
OpMemberDecorate %a_block 0 Offset 0
OpMemberDecorate %Outer_std140 0 Offset 0
OpMemberDecorate %Inner_std140 0 Offset 0
OpMemberDecorate %Inner_std140 1 Offset 8
OpMemberDecorate %Inner_std140 2 Offset 16
OpMemberDecorate %Inner_std140 3 Offset 24
OpDecorate %_arr_Inner_std140_uint_4 ArrayStride 32
OpDecorate %_arr_Outer_std140_uint_4 ArrayStride 128
OpDecorate %a NonWritable
OpDecorate %a DescriptorSet 0
OpDecorate %a Binding 0
OpMemberDecorate %Inner 0 Offset 0
OpMemberDecorate %Inner 0 ColMajor
OpMemberDecorate %Inner 0 MatrixStride 8
OpDecorate %_arr_Inner_uint_4 ArrayStride 32
OpMemberDecorate %Outer 0 Offset 0
OpDecorate %_arr_Outer_uint_4 ArrayStride 128
%float = OpTypeFloat 32
%v2float = OpTypeVector %float 2
%Inner_std140 = OpTypeStruct %v2float %v2float %v2float %v2float
%uint = OpTypeInt 32 0
%uint_4 = OpConstant %uint 4
%_arr_Inner_std140_uint_4 = OpTypeArray %Inner_std140 %uint_4
%Outer_std140 = OpTypeStruct %_arr_Inner_std140_uint_4
%_arr_Outer_std140_uint_4 = OpTypeArray %Outer_std140 %uint_4
%a_block = OpTypeStruct %_arr_Outer_std140_uint_4
%_ptr_Uniform_a_block = OpTypePointer Uniform %a_block
%a = OpVariable %_ptr_Uniform_a_block Uniform
%mat4v2float = OpTypeMatrix %v2float 4
%Inner = OpTypeStruct %mat4v2float
%12 = OpTypeFunction %Inner %Inner_std140
%_arr_Inner_uint_4 = OpTypeArray %Inner %uint_4
%24 = OpTypeFunction %_arr_Inner_uint_4 %_arr_Inner_std140_uint_4
%_ptr_Function__arr_Inner_uint_4 = OpTypePointer Function %_arr_Inner_uint_4
%31 = OpConstantNull %_arr_Inner_uint_4
%_ptr_Function_uint = OpTypePointer Function %uint
%34 = OpConstantNull %uint
%bool = OpTypeBool
%_ptr_Function__arr_Inner_std140_uint_4 = OpTypePointer Function %_arr_Inner_std140_uint_4
%47 = OpConstantNull %_arr_Inner_std140_uint_4
%_ptr_Function_Inner = OpTypePointer Function %Inner
%_ptr_Function_Inner_std140 = OpTypePointer Function %Inner_std140
%uint_1 = OpConstant %uint 1
%Outer = OpTypeStruct %_arr_Inner_uint_4
%60 = OpTypeFunction %Outer %Outer_std140
%_arr_Outer_uint_4 = OpTypeArray %Outer %uint_4
%68 = OpTypeFunction %_arr_Outer_uint_4 %_arr_Outer_std140_uint_4
%_ptr_Function__arr_Outer_uint_4 = OpTypePointer Function %_arr_Outer_uint_4
%75 = OpConstantNull %_arr_Outer_uint_4
%_ptr_Function__arr_Outer_std140_uint_4 = OpTypePointer Function %_arr_Outer_std140_uint_4
%88 = OpConstantNull %_arr_Outer_std140_uint_4
%_ptr_Function_Outer = OpTypePointer Function %Outer
%_ptr_Function_Outer_std140 = OpTypePointer Function %Outer_std140
%100 = OpTypeFunction %mat4v2float
%uint_0 = OpConstant %uint 0
%uint_3 = OpConstant %uint 3
%uint_2 = OpConstant %uint 2
%_ptr_Uniform_v2float = OpTypePointer Uniform %v2float
%void = OpTypeVoid
%116 = OpTypeFunction %void
%int = OpTypeInt 32 1
%int_1 = OpConstant %int 1
%_ptr_Uniform__arr_Outer_std140_uint_4 = OpTypePointer Uniform %_arr_Outer_std140_uint_4
%_ptr_Uniform_Outer_std140 = OpTypePointer Uniform %Outer_std140
%_ptr_Uniform__arr_Inner_std140_uint_4 = OpTypePointer Uniform %_arr_Inner_std140_uint_4
%_ptr_Uniform_Inner_std140 = OpTypePointer Uniform %Inner_std140
%_ptr_Uniform_float = OpTypePointer Uniform %float
%conv_Inner = OpFunction %Inner None %12
%val = OpFunctionParameter %Inner_std140
%17 = OpLabel
%18 = OpCompositeExtract %v2float %val 0
%19 = OpCompositeExtract %v2float %val 1
%20 = OpCompositeExtract %v2float %val 2
%21 = OpCompositeExtract %v2float %val 3
%22 = OpCompositeConstruct %mat4v2float %18 %19 %20 %21
%23 = OpCompositeConstruct %Inner %22
OpReturnValue %23
OpFunctionEnd
%conv_arr_4_Inner = OpFunction %_arr_Inner_uint_4 None %24
%val_0 = OpFunctionParameter %_arr_Inner_std140_uint_4
%28 = OpLabel
%arr = OpVariable %_ptr_Function__arr_Inner_uint_4 Function %31
%i = OpVariable %_ptr_Function_uint Function %34
%var_for_index = OpVariable %_ptr_Function__arr_Inner_std140_uint_4 Function %47
OpBranch %35
%35 = OpLabel
OpLoopMerge %36 %37 None
OpBranch %38
%38 = OpLabel
%40 = OpLoad %uint %i
%41 = OpULessThan %bool %40 %uint_4
%39 = OpLogicalNot %bool %41
OpSelectionMerge %43 None
OpBranchConditional %39 %44 %43
%44 = OpLabel
OpBranch %36
%43 = OpLabel
OpStore %var_for_index %val_0
%48 = OpLoad %uint %i
%50 = OpAccessChain %_ptr_Function_Inner %arr %48
%52 = OpLoad %uint %i
%54 = OpAccessChain %_ptr_Function_Inner_std140 %var_for_index %52
%55 = OpLoad %Inner_std140 %54
%51 = OpFunctionCall %Inner %conv_Inner %55
OpStore %50 %51
OpBranch %37
%37 = OpLabel
%56 = OpLoad %uint %i
%58 = OpIAdd %uint %56 %uint_1
OpStore %i %58
OpBranch %35
%36 = OpLabel
%59 = OpLoad %_arr_Inner_uint_4 %arr
OpReturnValue %59
OpFunctionEnd
%conv_Outer = OpFunction %Outer None %60
%val_1 = OpFunctionParameter %Outer_std140
%64 = OpLabel
%66 = OpCompositeExtract %_arr_Inner_std140_uint_4 %val_1 0
%65 = OpFunctionCall %_arr_Inner_uint_4 %conv_arr_4_Inner %66
%67 = OpCompositeConstruct %Outer %65
OpReturnValue %67
OpFunctionEnd
%conv_arr_4_Outer = OpFunction %_arr_Outer_uint_4 None %68
%val_2 = OpFunctionParameter %_arr_Outer_std140_uint_4
%72 = OpLabel
%arr_0 = OpVariable %_ptr_Function__arr_Outer_uint_4 Function %75
%i_0 = OpVariable %_ptr_Function_uint Function %34
%var_for_index_1 = OpVariable %_ptr_Function__arr_Outer_std140_uint_4 Function %88
OpBranch %77
%77 = OpLabel
OpLoopMerge %78 %79 None
OpBranch %80
%80 = OpLabel
%82 = OpLoad %uint %i_0
%83 = OpULessThan %bool %82 %uint_4
%81 = OpLogicalNot %bool %83
OpSelectionMerge %84 None
OpBranchConditional %81 %85 %84
%85 = OpLabel
OpBranch %78
%84 = OpLabel
OpStore %var_for_index_1 %val_2
%89 = OpLoad %uint %i_0
%91 = OpAccessChain %_ptr_Function_Outer %arr_0 %89
%93 = OpLoad %uint %i_0
%95 = OpAccessChain %_ptr_Function_Outer_std140 %var_for_index_1 %93
%96 = OpLoad %Outer_std140 %95
%92 = OpFunctionCall %Outer %conv_Outer %96
OpStore %91 %92
OpBranch %79
%79 = OpLabel
%97 = OpLoad %uint %i_0
%98 = OpIAdd %uint %97 %uint_1
OpStore %i_0 %98
OpBranch %77
%78 = OpLabel
%99 = OpLoad %_arr_Outer_uint_4 %arr_0
OpReturnValue %99
OpFunctionEnd
%load_a_3_a_2_m = OpFunction %mat4v2float None %100
%102 = OpLabel
%107 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_0
%108 = OpLoad %v2float %107
%109 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_1
%110 = OpLoad %v2float %109
%111 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_2
%112 = OpLoad %v2float %111
%113 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_3
%114 = OpLoad %v2float %113
%115 = OpCompositeConstruct %mat4v2float %108 %110 %112 %114
OpReturnValue %115
OpFunctionEnd
%f = OpFunction %void None %116
%119 = OpLabel
%124 = OpAccessChain %_ptr_Uniform__arr_Outer_std140_uint_4 %a %uint_0
%125 = OpLoad %_arr_Outer_std140_uint_4 %124
%122 = OpFunctionCall %_arr_Outer_uint_4 %conv_arr_4_Outer %125
%128 = OpAccessChain %_ptr_Uniform_Outer_std140 %a %uint_0 %uint_3
%129 = OpLoad %Outer_std140 %128
%126 = OpFunctionCall %Outer %conv_Outer %129
%132 = OpAccessChain %_ptr_Uniform__arr_Inner_std140_uint_4 %a %uint_0 %uint_3 %uint_0
%133 = OpLoad %_arr_Inner_std140_uint_4 %132
%130 = OpFunctionCall %_arr_Inner_uint_4 %conv_arr_4_Inner %133
%136 = OpAccessChain %_ptr_Uniform_Inner_std140 %a %uint_0 %uint_3 %uint_0 %uint_2
%137 = OpLoad %Inner_std140 %136
%134 = OpFunctionCall %Inner %conv_Inner %137
%138 = OpFunctionCall %mat4v2float %load_a_3_a_2_m
%139 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_1
%140 = OpLoad %v2float %139
%142 = OpAccessChain %_ptr_Uniform__arr_Outer_std140_uint_4 %a %uint_0
%143 = OpLoad %_arr_Outer_std140_uint_4 %142
%141 = OpFunctionCall %_arr_Outer_uint_4 %conv_arr_4_Outer %143
%145 = OpAccessChain %_ptr_Uniform_Outer_std140 %a %uint_0 %uint_3
%146 = OpLoad %Outer_std140 %145
%144 = OpFunctionCall %Outer %conv_Outer %146
%148 = OpAccessChain %_ptr_Uniform__arr_Inner_std140_uint_4 %a %uint_0 %uint_3 %uint_0
%149 = OpLoad %_arr_Inner_std140_uint_4 %148
%147 = OpFunctionCall %_arr_Inner_uint_4 %conv_arr_4_Inner %149
%151 = OpAccessChain %_ptr_Uniform_Inner_std140 %a %uint_0 %uint_3 %uint_0 %uint_2
%152 = OpLoad %Inner_std140 %151
%150 = OpFunctionCall %Inner %conv_Inner %152
%153 = OpFunctionCall %mat4v2float %load_a_3_a_2_m
%154 = OpAccessChain %_ptr_Uniform_v2float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_1
%155 = OpLoad %v2float %154
%157 = OpAccessChain %_ptr_Uniform_float %a %uint_0 %uint_3 %uint_0 %uint_2 %uint_1 %34
%158 = OpLoad %float %157
OpReturn
OpFunctionEnd