blob: b6b2b5747d5ce58ee4a651dacb72b793f732f45b [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 98
; 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_float_values"
OpName %x_7 "x_7"
OpName %x_GLF_color "x_GLF_color"
OpName %buf1 "buf1"
OpMemberName %buf1 0 "x_GLF_uniform_int_values"
OpName %x_11 "x_11"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %func_ "func_"
OpName %v "v"
OpName %a "a"
OpName %indexable "indexable"
OpName %main_1 "main_1"
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_float_uint_2 ArrayStride 16
OpDecorate %x_7 NonWritable
OpDecorate %x_7 DescriptorSet 0
OpDecorate %x_7 Binding 0
OpDecorate %buf1 Block
OpMemberDecorate %buf1 0 Offset 0
OpDecorate %_arr_int_uint_2 ArrayStride 16
OpDecorate %x_11 NonWritable
OpDecorate %x_11 DescriptorSet 0
OpDecorate %x_11 Binding 1
OpDecorate %tint_symbol_1 Location 0
OpDecorate %_arr_v2float_uint_3 ArrayStride 8
OpMemberDecorate %main_out 0 Offset 0
%float = OpTypeFloat 32
%uint = OpTypeInt 32 0
%uint_2 = OpConstant %uint 2
%_arr_float_uint_2 = OpTypeArray %float %uint_2
%buf0 = OpTypeStruct %_arr_float_uint_2
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_7 = OpVariable %_ptr_Uniform_buf0 Uniform
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%11 = OpConstantNull %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %11
%int = OpTypeInt 32 1
%_arr_int_uint_2 = OpTypeArray %int %uint_2
%buf1 = OpTypeStruct %_arr_int_uint_2
%_ptr_Uniform_buf1 = OpTypePointer Uniform %buf1
%x_11 = OpVariable %_ptr_Uniform_buf1 Uniform
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %11
%v2float = OpTypeVector %float 2
%19 = OpTypeFunction %v2float
%_ptr_Function_v2float = OpTypePointer Function %v2float
%25 = OpConstantNull %v2float
%_ptr_Function_int = OpTypePointer Function %int
%28 = OpConstantNull %int
%uint_3 = OpConstant %uint 3
%_arr_v2float_uint_3 = OpTypeArray %v2float %uint_3
%_ptr_Function__arr_v2float_uint_3 = OpTypePointer Function %_arr_v2float_uint_3
%33 = OpConstantNull %_arr_v2float_uint_3
%uint_0 = OpConstant %uint 0
%int_0 = OpConstant %int 0
%_ptr_Uniform_float = OpTypePointer Uniform %float
%uint_1 = OpConstant %uint 1
%_ptr_Function_float = OpTypePointer Function %float
%int_2 = OpConstant %int 2
%int_1 = OpConstant %int 1
%void = OpTypeVoid
%55 = OpTypeFunction %void
%bool = OpTypeBool
%_ptr_Uniform_int = OpTypePointer Uniform %int
%main_out = OpTypeStruct %v4float
%86 = OpTypeFunction %void %main_out
%func_ = OpFunction %v2float None %19
%22 = OpLabel
%v = OpVariable %_ptr_Function_v2float Function %25
%a = OpVariable %_ptr_Function_int Function %28
%indexable = OpVariable %_ptr_Function__arr_v2float_uint_3 Function %33
%37 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%38 = OpLoad %float %37
%41 = OpAccessChain %_ptr_Function_float %v %uint_1
OpStore %41 %38
OpStore %a %int_2
%44 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_1
%45 = OpLoad %float %44
%46 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_1
%47 = OpLoad %float %46
%48 = OpLoad %v2float %v
%49 = OpLoad %int %a
%50 = OpCompositeConstruct %v2float %45 %45
%51 = OpCompositeConstruct %v2float %47 %47
%52 = OpCompositeConstruct %_arr_v2float_uint_3 %50 %51 %48
OpStore %indexable %52
%53 = OpAccessChain %_ptr_Function_v2float %indexable %49
%54 = OpLoad %v2float %53
OpReturnValue %54
OpFunctionEnd
%main_1 = OpFunction %void None %55
%58 = OpLabel
%59 = OpFunctionCall %v2float %func_
%60 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%61 = OpLoad %float %60
%62 = OpCompositeExtract %float %59 1
%63 = OpFOrdEqual %bool %62 %61
OpSelectionMerge %65 None
OpBranchConditional %63 %66 %67
%66 = OpLabel
%69 = OpAccessChain %_ptr_Uniform_int %x_11 %uint_0 %int_0
%70 = OpLoad %int %69
%71 = OpAccessChain %_ptr_Uniform_int %x_11 %uint_0 %int_1
%72 = OpLoad %int %71
%73 = OpAccessChain %_ptr_Uniform_int %x_11 %uint_0 %int_1
%74 = OpLoad %int %73
%75 = OpAccessChain %_ptr_Uniform_int %x_11 %uint_0 %int_0
%76 = OpLoad %int %75
%77 = OpConvertSToF %float %70
%78 = OpConvertSToF %float %72
%79 = OpConvertSToF %float %74
%80 = OpConvertSToF %float %76
%81 = OpCompositeConstruct %v4float %77 %78 %79 %80
OpStore %x_GLF_color %81
OpBranch %65
%67 = OpLabel
%82 = OpAccessChain %_ptr_Uniform_int %x_11 %uint_0 %int_1
%83 = OpLoad %int %82
%84 = OpConvertSToF %float %83
%85 = OpCompositeConstruct %v4float %84 %84 %84 %84
OpStore %x_GLF_color %85
OpBranch %65
%65 = OpLabel
OpReturn
OpFunctionEnd
%tint_symbol_2 = OpFunction %void None %86
%tint_symbol = OpFunctionParameter %main_out
%90 = OpLabel
%91 = OpCompositeExtract %v4float %tint_symbol 0
OpStore %tint_symbol_1 %91
OpReturn
OpFunctionEnd
%main = OpFunction %void None %55
%93 = OpLabel
%94 = OpFunctionCall %void %main_1
%96 = OpLoad %v4float %x_GLF_color
%97 = OpCompositeConstruct %main_out %96
%95 = OpFunctionCall %void %tint_symbol_2 %97
OpReturn
OpFunctionEnd