blob: 7bf94abd0ee15db625fc561ffad104fb8a60a5a2 [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 49
; Schema: 0
OpCapability Shader
OpCapability Float16
OpCapability UniformAndStorageBuffer16BitAccess
OpCapability StorageBuffer16BitAccess
OpCapability StorageInputOutput16
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %f "f"
OpExecutionMode %f LocalSize 1 1 1
OpName %u_block_std140 "u_block_std140"
OpMemberName %u_block_std140 0 "inner_0"
OpMemberName %u_block_std140 1 "inner_1"
OpName %u "u"
OpName %u_block "u_block"
OpMemberName %u_block 0 "inner"
OpName %s "s"
OpName %load_u_inner "load_u_inner"
OpName %f "f"
OpDecorate %u_block_std140 Block
OpMemberDecorate %u_block_std140 0 Offset 0
OpMemberDecorate %u_block_std140 1 Offset 4
OpDecorate %u NonWritable
OpDecorate %u DescriptorSet 0
OpDecorate %u Binding 0
OpDecorate %u_block Block
OpMemberDecorate %u_block 0 Offset 0
OpMemberDecorate %u_block 0 ColMajor
OpMemberDecorate %u_block 0 MatrixStride 4
OpDecorate %s DescriptorSet 0
OpDecorate %s Binding 1
%half = OpTypeFloat 16
%v2half = OpTypeVector %half 2
%u_block_std140 = OpTypeStruct %v2half %v2half
%_ptr_Uniform_u_block_std140 = OpTypePointer Uniform %u_block_std140
%u = OpVariable %_ptr_Uniform_u_block_std140 Uniform
%mat2v2half = OpTypeMatrix %v2half 2
%u_block = OpTypeStruct %mat2v2half
%_ptr_StorageBuffer_u_block = OpTypePointer StorageBuffer %u_block
%s = OpVariable %_ptr_StorageBuffer_u_block StorageBuffer
%10 = OpTypeFunction %mat2v2half
%uint = OpTypeInt 32 0
%uint_0 = OpConstant %uint 0
%_ptr_Uniform_v2half = OpTypePointer Uniform %v2half
%uint_1 = OpConstant %uint 1
%void = OpTypeVoid
%25 = OpTypeFunction %void
%_ptr_StorageBuffer_mat2v2half = OpTypePointer StorageBuffer %mat2v2half
%int = OpTypeInt 32 1
%int_1 = OpConstant %int 1
%_ptr_StorageBuffer_v2half = OpTypePointer StorageBuffer %v2half
%42 = OpConstantNull %int
%_ptr_StorageBuffer_half = OpTypePointer StorageBuffer %half
%45 = OpConstantNull %uint
%_ptr_Uniform_half = OpTypePointer Uniform %half
%load_u_inner = OpFunction %mat2v2half None %10
%12 = OpLabel
%18 = OpAccessChain %_ptr_Uniform_v2half %u %uint_0
%19 = OpLoad %v2half %18
%22 = OpAccessChain %_ptr_Uniform_v2half %u %uint_1
%23 = OpLoad %v2half %22
%24 = OpCompositeConstruct %mat2v2half %19 %23
OpReturnValue %24
OpFunctionEnd
%f = OpFunction %void None %25
%28 = OpLabel
%30 = OpAccessChain %_ptr_StorageBuffer_mat2v2half %s %uint_0
%31 = OpFunctionCall %mat2v2half %load_u_inner
OpStore %30 %31
%35 = OpAccessChain %_ptr_StorageBuffer_v2half %s %uint_0 %int_1
%36 = OpAccessChain %_ptr_Uniform_v2half %u %uint_0
%37 = OpLoad %v2half %36
OpStore %35 %37
%38 = OpAccessChain %_ptr_StorageBuffer_v2half %s %uint_0 %int_1
%39 = OpAccessChain %_ptr_Uniform_v2half %u %uint_0
%40 = OpLoad %v2half %39
%41 = OpVectorShuffle %v2half %40 %40 1 0
OpStore %38 %41
%44 = OpAccessChain %_ptr_StorageBuffer_half %s %uint_0 %42 %int_1
%47 = OpAccessChain %_ptr_Uniform_half %u %uint_1 %45
%48 = OpLoad %half %47
OpStore %44 %48
OpReturn
OpFunctionEnd