blob: fb6a04dc877dedc24caaf47077171db6ee6d302b [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 1
; Bound: 33
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %main "main"
OpExecutionMode %main LocalSize 1 1 1
OpMemberName %tint_symbol_1 0 "tint_symbol"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %foo "foo"
OpName %main "main"
OpName %v "v"
OpMemberDecorate %tint_symbol_1 0 Offset 0
OpDecorate %tint_symbol_1 Block
OpDecorate %1 DescriptorSet 0
OpDecorate %1 Binding 0
OpDecorate %_arr_uint_uint_4 ArrayStride 4
%uint = OpTypeInt 32 0
%tint_symbol_1 = OpTypeStruct %uint
%_ptr_StorageBuffer_tint_symbol_1 = OpTypePointer StorageBuffer %tint_symbol_1
%1 = OpVariable %_ptr_StorageBuffer_tint_symbol_1 StorageBuffer
%uint_4 = OpConstant %uint 4
%_arr_uint_uint_4 = OpTypeArray %uint %uint_4
%_ptr_Private__arr_uint_uint_4 = OpTypePointer Private %_arr_uint_uint_4
%uint_0 = OpConstant %uint 0
%uint_1 = OpConstant %uint 1
%uint_2 = OpConstant %uint 2
%9 = OpConstantComposite %_arr_uint_uint_4 %uint_0 %uint_1 %uint_2 %uint_4
%5 = OpVariable %_ptr_Private__arr_uint_uint_4 Private %9
%14 = OpTypeFunction %uint
%_ptr_StorageBuffer_uint = OpTypePointer StorageBuffer %uint
%_ptr_Private_uint = OpTypePointer Private %uint
%void = OpTypeVoid
%24 = OpTypeFunction %void
%foo = OpFunction %uint None %14
%15 = OpLabel
%16 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0
%18 = OpLoad %uint %16
%19 = OpAccessChain %_ptr_Private_uint %5 %18
%21 = OpLoad %uint %19
OpReturnValue %21
OpFunctionEnd
%main = OpFunction %void None %24
%25 = OpLabel
%26 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0
%27 = OpLoad %uint %26
%28 = OpAccessChain %_ptr_Private_uint %5 %27
%v = OpLoad %uint %28
%30 = OpFunctionCall %uint %foo
%31 = OpIAdd %uint %v %30
%32 = OpAccessChain %_ptr_StorageBuffer_uint %1 %uint_0
OpStore %32 %31
OpReturn
OpFunctionEnd