blob: b2ec6d530d25d0b163b95f63eab5cc5b6e0e18ca [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 74
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %tint_symbol_1
OpExecutionMode %main OriginUpperLeft
OpName %buf0 "buf0"
OpMemberName %buf0 0 "x_GLF_uniform_int_values"
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 %a "a"
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 %_arr_int_uint_3 ArrayStride 16
OpDecorate %x_6 NonWritable
OpDecorate %x_6 DescriptorSet 0
OpDecorate %x_6 Binding 0
OpDecorate %tint_symbol_1 Location 0
OpMemberDecorate %main_out 0 Offset 0
%int = OpTypeInt 32 1
%uint = OpTypeInt 32 0
%uint_3 = OpConstant %uint 3
%_arr_int_uint_3 = OpTypeArray %int %uint_3
%buf0 = OpTypeStruct %_arr_int_uint_3
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_6 = OpVariable %_ptr_Uniform_buf0 Uniform
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%12 = OpConstantNull %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %12
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %12
%void = OpTypeVoid
%15 = OpTypeFunction %void
%_ptr_Function_int = OpTypePointer Function %int
%21 = OpConstantNull %int
%uint_0 = OpConstant %uint 0
%int_1 = OpConstant %int 1
%_ptr_Uniform_int = OpTypePointer Uniform %int
%int_2 = OpConstant %int 2
%int_0 = OpConstant %int 0
%v2int = OpTypeVector %int 2
%int_63677 = OpConstant %int 63677
%bool = OpTypeBool
%main_out = OpTypeStruct %v4float
%62 = OpTypeFunction %void %main_out
%main_1 = OpFunction %void None %15
%18 = OpLabel
%a = OpVariable %_ptr_Function_int Function %21
%25 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_1
%26 = OpLoad %int %25
OpStore %a %26
%27 = OpLoad %int %a
%29 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_2
%30 = OpLoad %int %29
%32 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_0
%33 = OpLoad %int %32
%35 = OpCompositeConstruct %v2int %27 %27
%37 = OpCompositeConstruct %v2int %30 %int_63677
%38 = OpSDiv %v2int %35 %37
%39 = OpCompositeExtract %int %38 1
%40 = OpIEqual %bool %39 %33
OpSelectionMerge %42 None
OpBranchConditional %40 %43 %44
%43 = OpLabel
%45 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_2
%46 = OpLoad %int %45
%47 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_0
%48 = OpLoad %int %47
%49 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_0
%50 = OpLoad %int %49
%51 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_2
%52 = OpLoad %int %51
%53 = OpConvertSToF %float %46
%54 = OpConvertSToF %float %48
%55 = OpConvertSToF %float %50
%56 = OpConvertSToF %float %52
%57 = OpCompositeConstruct %v4float %53 %54 %55 %56
OpStore %x_GLF_color %57
OpBranch %42
%44 = OpLabel
%58 = OpAccessChain %_ptr_Uniform_int %x_6 %uint_0 %int_0
%59 = OpLoad %int %58
%60 = OpConvertSToF %float %59
%61 = OpCompositeConstruct %v4float %60 %60 %60 %60
OpStore %x_GLF_color %61
OpBranch %42
%42 = OpLabel
OpReturn
OpFunctionEnd
%tint_symbol_2 = OpFunction %void None %62
%tint_symbol = OpFunctionParameter %main_out
%66 = OpLabel
%67 = OpCompositeExtract %v4float %tint_symbol 0
OpStore %tint_symbol_1 %67
OpReturn
OpFunctionEnd
%main = OpFunction %void None %15
%69 = OpLabel
%70 = OpFunctionCall %void %main_1
%72 = OpLoad %v4float %x_GLF_color
%73 = OpCompositeConstruct %main_out %72
%71 = OpFunctionCall %void %tint_symbol_2 %73
OpReturn
OpFunctionEnd