blob: 556a05f25d9245493942e688c4f3266e0eecc5a4 [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 90
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %tint_symbol_1
OpExecutionMode %main OriginUpperLeft
OpName %buf0 "buf0"
OpMemberName %buf0 0 "injectionSwitch"
OpName %x_6 "x_6"
OpName %x_GLF_color "x_GLF_color"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %main_1 "main_1"
OpName %data "data"
OpName %x_40 "x_40"
OpName %x_40_phi "x_40_phi"
OpName %x_11_phi "x_11_phi"
OpName %x_54 "x_54"
OpName %x_41 "x_41"
OpName %x_41_phi "x_41_phi"
OpName %x_54_phi "x_54_phi"
OpName %main_out "main_out"
OpMemberName %main_out 0 "x_GLF_color_1"
OpName %tint_symbol_2 "tint_symbol_2"
OpName %tint_symbol "tint_symbol"
OpName %main "main"
OpDecorate %buf0 Block
OpMemberDecorate %buf0 0 Offset 0
OpDecorate %x_6 NonWritable
OpDecorate %x_6 DescriptorSet 0
OpDecorate %x_6 Binding 0
OpDecorate %tint_symbol_1 Location 0
OpDecorate %_arr_int_uint_10 ArrayStride 4
OpMemberDecorate %main_out 0 Offset 0
%float = OpTypeFloat 32
%v2float = OpTypeVector %float 2
%buf0 = OpTypeStruct %v2float
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_6 = OpVariable %_ptr_Uniform_buf0 Uniform
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%9 = OpConstantNull %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %9
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %9
%void = OpTypeVoid
%12 = OpTypeFunction %void
%int = OpTypeInt 32 1
%uint = OpTypeInt 32 0
%uint_10 = OpConstant %uint 10
%_arr_int_uint_10 = OpTypeArray %int %uint_10
%_ptr_Function__arr_int_uint_10 = OpTypePointer Function %_arr_int_uint_10
%22 = OpConstantNull %_arr_int_uint_10
%_ptr_Function_int = OpTypePointer Function %int
%25 = OpConstantNull %int
%int_1 = OpConstant %int 1
%bool = OpTypeBool
%int_2 = OpConstant %int 2
%int_3 = OpConstant %int 3
%uint_0 = OpConstant %uint 0
%_ptr_Uniform_float = OpTypePointer Uniform %float
%float_1 = OpConstant %float 1
%63 = OpConstantComposite %v4float %float_1 %float_1 %float_1 %float_1
%int_0 = OpConstant %int 0
%float_0 = OpConstant %float 0
%77 = OpConstantComposite %v4float %float_1 %float_0 %float_0 %float_1
%main_out = OpTypeStruct %v4float
%78 = OpTypeFunction %void %main_out
%main_1 = OpFunction %void None %12
%15 = OpLabel
%data = OpVariable %_ptr_Function__arr_int_uint_10 Function %22
%x_40 = OpVariable %_ptr_Function_int Function %25
%x_40_phi = OpVariable %_ptr_Function_int Function %25
%x_11_phi = OpVariable %_ptr_Function_int Function %25
%x_54 = OpVariable %_ptr_Function_int Function %25
%x_41 = OpVariable %_ptr_Function_int Function %25
%x_41_phi = OpVariable %_ptr_Function_int Function %25
%x_54_phi = OpVariable %_ptr_Function_int Function %25
%29 = OpAccessChain %_ptr_Function_int %data %int_1
%30 = OpLoad %int %29
%32 = OpSLessThan %bool %int_1 %30
%31 = OpSelect %int %32 %int_2 %int_1
OpStore %x_40_phi %int_1
OpStore %x_11_phi %31
OpBranch %35
%35 = OpLabel
OpLoopMerge %36 %37 None
OpBranch %38
%38 = OpLabel
%42 = OpLoad %int %x_40_phi
OpStore %x_40 %42
%43 = OpLoad %int %x_11_phi
%45 = OpSLessThan %bool %43 %int_3
OpSelectionMerge %46 None
OpBranchConditional %45 %47 %48
%47 = OpLabel
OpBranch %46
%48 = OpLabel
OpBranch %36
%46 = OpLabel
%50 = OpIAdd %int %43 %int_1
%53 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %uint_0
%54 = OpLoad %float %53
%55 = OpLoad %int %x_40
OpStore %x_54_phi %55
%57 = OpConvertFToS %int %54
OpSelectionMerge %56 None
OpSwitch %57 %58 78 %59 19 %60 23 %61 38 %61
%59 = OpLabel
OpStore %x_GLF_color %63
OpBranch %60
%60 = OpLabel
%65 = OpLoad %int %x_40
%66 = OpCopyObject %int %int_1
%67 = OpIAdd %int %65 %66
%64 = OpCopyObject %int %67
OpStore %x_54_phi %64
OpBranch %61
%61 = OpLabel
%68 = OpLoad %int %x_54_phi
OpStore %x_54 %68
%69 = OpLoad %int %x_54
OpStore %x_41_phi %69
OpBranch %37
%58 = OpLabel
%70 = OpLoad %int %x_40
OpStore %x_41_phi %70
OpBranch %37
%56 = OpLabel
OpStore %x_41_phi %int_0
OpBranch %37
%37 = OpLabel
%72 = OpLoad %int %x_41_phi
OpStore %x_41 %72
%73 = OpLoad %int %x_41
OpStore %x_40_phi %73
OpStore %x_11_phi %50
OpBranch %35
%36 = OpLabel
%74 = OpLoad %int %x_40
%75 = OpAccessChain %_ptr_Function_int %data %74
OpStore %75 %int_1
OpStore %x_GLF_color %77
OpReturn
OpFunctionEnd
%tint_symbol_2 = OpFunction %void None %78
%tint_symbol = OpFunctionParameter %main_out
%82 = OpLabel
%83 = OpCompositeExtract %v4float %tint_symbol 0
OpStore %tint_symbol_1 %83
OpReturn
OpFunctionEnd
%main = OpFunction %void None %12
%85 = OpLabel
%86 = OpFunctionCall %void %main_1
%88 = OpLoad %v4float %x_GLF_color
%89 = OpCompositeConstruct %main_out %88
%87 = OpFunctionCall %void %tint_symbol_2 %89
OpReturn
OpFunctionEnd