dawn-cmake/test/shader_io/compute_input_builtins.wgsl...

44 lines
1.8 KiB
Plaintext
Raw Normal View History

; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 24
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint GLCompute %main "main" %tint_symbol %tint_symbol_1 %tint_symbol_2 %tint_symbol_3
OpExecutionMode %main LocalSize 1 1 1
OpName %tint_symbol "tint_symbol"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %tint_symbol_2 "tint_symbol_2"
OpName %tint_symbol_3 "tint_symbol_3"
OpName %main "main"
OpDecorate %tint_symbol BuiltIn LocalInvocationId
OpDecorate %tint_symbol_1 BuiltIn LocalInvocationIndex
OpDecorate %tint_symbol_2 BuiltIn GlobalInvocationId
OpDecorate %tint_symbol_3 BuiltIn WorkgroupId
%uint = OpTypeInt 32 0
%v3uint = OpTypeVector %uint 3
%_ptr_Input_v3uint = OpTypePointer Input %v3uint
%tint_symbol = OpVariable %_ptr_Input_v3uint Input
%_ptr_Input_uint = OpTypePointer Input %uint
%tint_symbol_1 = OpVariable %_ptr_Input_uint Input
%tint_symbol_2 = OpVariable %_ptr_Input_v3uint Input
%tint_symbol_3 = OpVariable %_ptr_Input_v3uint Input
%void = OpTypeVoid
%9 = OpTypeFunction %void
%uint_0 = OpConstant %uint 0
%main = OpFunction %void None %9
%12 = OpLabel
%14 = OpAccessChain %_ptr_Input_uint %tint_symbol %uint_0
%15 = OpLoad %uint %14
%16 = OpLoad %uint %tint_symbol_1
%17 = OpIAdd %uint %15 %16
%18 = OpAccessChain %_ptr_Input_uint %tint_symbol_2 %uint_0
%19 = OpLoad %uint %18
%20 = OpIAdd %uint %17 %19
%21 = OpAccessChain %_ptr_Input_uint %tint_symbol_3 %uint_0
%22 = OpLoad %uint %21
%23 = OpIAdd %uint %20 %22
OpReturn
OpFunctionEnd