blob: 6114885f3fc0b25fd980c2db1db242eeaf3e0950 [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 62
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %tint_symbol_1
OpExecutionMode %main OriginUpperLeft
OpName %x_GLF_color "x_GLF_color"
OpName %buf0 "buf0"
OpMemberName %buf0 0 "x_GLF_uniform_float_values"
OpName %x_6 "x_6"
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_float_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
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%5 = OpConstantNull %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %5
%uint = OpTypeInt 32 0
%uint_3 = OpConstant %uint 3
%_arr_float_uint_3 = OpTypeArray %float %uint_3
%buf0 = OpTypeStruct %_arr_float_uint_3
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_6 = OpVariable %_ptr_Uniform_buf0 Uniform
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %5
%void = OpTypeVoid
%14 = OpTypeFunction %void
%_ptr_Function_float = OpTypePointer Function %float
%20 = OpConstantNull %float
%uint_1 = OpConstant %uint 1
%float_1 = OpConstant %float 1
%uint_0 = OpConstant %uint 0
%int = OpTypeInt 32 1
%int_1 = OpConstant %int 1
%_ptr_Uniform_float = OpTypePointer Uniform %float
%int_2 = OpConstant %int 2
%bool = OpTypeBool
%int_0 = OpConstant %int 0
%main_out = OpTypeStruct %v4float
%50 = OpTypeFunction %void %main_out
%main_1 = OpFunction %void None %14
%17 = OpLabel
%a = OpVariable %_ptr_Function_float Function %20
%21 = OpBitcast %float %uint_1
%24 = OpFRem %float %21 %float_1
OpStore %a %24
%29 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_1
%30 = OpLoad %float %29
%31 = OpCompositeConstruct %v4float %30 %30 %30 %30
OpStore %x_GLF_color %31
%32 = OpLoad %float %a
%34 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_2
%35 = OpLoad %float %34
%36 = OpFOrdLessThan %bool %32 %35
OpSelectionMerge %38 None
OpBranchConditional %36 %39 %38
%39 = OpLabel
%41 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_0
%42 = OpLoad %float %41
%43 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_1
%44 = OpLoad %float %43
%45 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_1
%46 = OpLoad %float %45
%47 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0 %int_0
%48 = OpLoad %float %47
%49 = OpCompositeConstruct %v4float %42 %44 %46 %48
OpStore %x_GLF_color %49
OpBranch %38
%38 = OpLabel
OpReturn
OpFunctionEnd
%tint_symbol_2 = OpFunction %void None %50
%tint_symbol = OpFunctionParameter %main_out
%54 = OpLabel
%55 = OpCompositeExtract %v4float %tint_symbol 0
OpStore %tint_symbol_1 %55
OpReturn
OpFunctionEnd
%main = OpFunction %void None %14
%57 = OpLabel
%58 = OpFunctionCall %void %main_1
%60 = OpLoad %v4float %x_GLF_color
%61 = OpCompositeConstruct %main_out %60
%59 = OpFunctionCall %void %tint_symbol_2 %61
OpReturn
OpFunctionEnd