blob: d631a2e31388d3694993cd729d79612975ee93fe [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 47
; Schema: 0
OpCapability Shader
%27 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %f "f"
OpExecutionMode %f LocalSize 1 1 1
OpName %u_block "u_block"
OpMemberName %u_block 0 "inner"
OpName %u "u"
OpName %s_block "s_block"
OpMemberName %s_block 0 "inner"
OpName %s "s"
OpName %f "f"
OpDecorate %u_block Block
OpMemberDecorate %u_block 0 Offset 0
OpMemberDecorate %u_block 0 ColMajor
OpMemberDecorate %u_block 0 MatrixStride 16
OpDecorate %_arr_mat2v4float_uint_4 ArrayStride 32
OpDecorate %u NonWritable
OpDecorate %u DescriptorSet 0
OpDecorate %u Binding 0
OpDecorate %s_block Block
OpMemberDecorate %s_block 0 Offset 0
OpDecorate %s DescriptorSet 0
OpDecorate %s Binding 1
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%mat2v4float = OpTypeMatrix %v4float 2
%uint = OpTypeInt 32 0
%uint_4 = OpConstant %uint 4
%_arr_mat2v4float_uint_4 = OpTypeArray %mat2v4float %uint_4
%u_block = OpTypeStruct %_arr_mat2v4float_uint_4
%_ptr_Uniform_u_block = OpTypePointer Uniform %u_block
%u = OpVariable %_ptr_Uniform_u_block Uniform
%s_block = OpTypeStruct %float
%_ptr_StorageBuffer_s_block = OpTypePointer StorageBuffer %s_block
%s = OpVariable %_ptr_StorageBuffer_s_block StorageBuffer
%void = OpTypeVoid
%13 = OpTypeFunction %void
%v2float = OpTypeVector %float 2
%mat4v2float = OpTypeMatrix %v2float 4
%uint_0 = OpConstant %uint 0
%int = OpTypeInt 32 1
%int_2 = OpConstant %int 2
%_ptr_Uniform_mat2v4float = OpTypePointer Uniform %mat2v4float
%28 = OpConstantNull %int
%int_1 = OpConstant %int 1
%_ptr_Uniform_v4float = OpTypePointer Uniform %v4float
%_ptr_StorageBuffer_float = OpTypePointer StorageBuffer %float
%f = OpFunction %void None %13
%16 = OpLabel
%24 = OpAccessChain %_ptr_Uniform_mat2v4float %u %uint_0 %int_2
%25 = OpLoad %mat2v4float %24
%17 = OpTranspose %mat4v2float %25
%31 = OpAccessChain %_ptr_Uniform_v4float %u %uint_0 %28 %int_1
%32 = OpLoad %v4float %31
%33 = OpVectorShuffle %v4float %32 %32 1 3 0 2
%26 = OpExtInst %float %27 Length %33
%35 = OpAccessChain %_ptr_Uniform_v4float %u %uint_0 %28 %int_1
%36 = OpLoad %v4float %35
%37 = OpVectorShuffle %v4float %36 %36 1 3 0 2
%38 = OpCompositeExtract %float %37 0
%34 = OpExtInst %float %27 FAbs %38
%40 = OpAccessChain %_ptr_StorageBuffer_float %s %uint_0
%41 = OpCompositeExtract %v2float %17 0
%42 = OpCompositeExtract %float %41 0
%44 = OpFAdd %float %42 %26
%46 = OpFAdd %float %44 %34
OpStore %40 %46
OpReturn
OpFunctionEnd