blob: 68c8ccd8a1746b9eece349539e94dd3a0cba813a [file] [log] [blame] [edit]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 37
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %main "main"
OpExecutionMode %main LocalSize 1 1 1
OpName %Particles "Particles"
OpMemberName %Particles 0 "p"
OpName %Particle "Particle"
OpMemberName %Particle 0 "position"
OpMemberName %Particle 1 "lifetime"
OpMemberName %Particle 2 "color"
OpMemberName %Particle 3 "velocity"
OpName %particles "particles"
OpName %Simulation "Simulation"
OpMemberName %Simulation 0 "i"
OpName %sim "sim"
OpName %main "main"
OpName %particle "particle"
OpDecorate %Particles Block
OpMemberDecorate %Particles 0 Offset 0
OpMemberDecorate %Particle 0 Offset 0
OpDecorate %_arr_v3float_uint_8 ArrayStride 16
OpMemberDecorate %Particle 1 Offset 128
OpMemberDecorate %Particle 2 Offset 144
OpMemberDecorate %Particle 3 Offset 160
OpDecorate %_runtimearr_Particle ArrayStride 176
OpDecorate %particles NonWritable
OpDecorate %particles DescriptorSet 1
OpDecorate %particles Binding 3
OpDecorate %Simulation Block
OpMemberDecorate %Simulation 0 Offset 0
OpDecorate %sim NonWritable
OpDecorate %sim DescriptorSet 1
OpDecorate %sim Binding 4
%float = OpTypeFloat 32
%v3float = OpTypeVector %float 3
%uint = OpTypeInt 32 0
%uint_8 = OpConstant %uint 8
%_arr_v3float_uint_8 = OpTypeArray %v3float %uint_8
%v4float = OpTypeVector %float 4
%Particle = OpTypeStruct %_arr_v3float_uint_8 %float %v4float %v3float
%_runtimearr_Particle = OpTypeRuntimeArray %Particle
%Particles = OpTypeStruct %_runtimearr_Particle
%_ptr_StorageBuffer_Particles = OpTypePointer StorageBuffer %Particles
%particles = OpVariable %_ptr_StorageBuffer_Particles StorageBuffer
%Simulation = OpTypeStruct %uint
%_ptr_Uniform_Simulation = OpTypePointer Uniform %Simulation
%sim = OpVariable %_ptr_Uniform_Simulation Uniform
%void = OpTypeVoid
%15 = OpTypeFunction %void
%uint_0 = OpConstant %uint 0
%int = OpTypeInt 32 1
%int_0 = OpConstant %int 0
%_ptr_StorageBuffer_Particle = OpTypePointer StorageBuffer %Particle
%_ptr_Function_Particle = OpTypePointer Function %Particle
%27 = OpConstantNull %Particle
%_ptr_Uniform_uint = OpTypePointer Uniform %uint
%_ptr_Function_v3float = OpTypePointer Function %v3float
%main = OpFunction %void None %15
%18 = OpLabel
%particle = OpVariable %_ptr_Function_Particle Function %27
%23 = OpAccessChain %_ptr_StorageBuffer_Particle %particles %uint_0 %int_0
%24 = OpLoad %Particle %23
OpStore %particle %24
%29 = OpAccessChain %_ptr_Uniform_uint %sim %uint_0
%30 = OpLoad %uint %29
%32 = OpAccessChain %_ptr_Function_v3float %particle %uint_0 %30
%33 = OpAccessChain %_ptr_Uniform_uint %sim %uint_0
%34 = OpLoad %uint %33
%35 = OpAccessChain %_ptr_Function_v3float %particle %uint_0 %34
%36 = OpLoad %v3float %35
OpStore %32 %36
OpReturn
OpFunctionEnd