blob: fa863d8893b3ccd46cc3d0ef5b822cb1ccdc39d9 [file] [log] [blame]
OpCapability Shader
%1 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %gl_FragCoord %_GLF_color
OpExecutionMode %main OriginUpperLeft
OpSource ESSL 310
OpName %main "main"
OpName %i "i"
OpName %buf1 "buf1"
OpMemberName %buf1 0 "_GLF_uniform_int_values"
OpName %_ ""
OpName %arr "arr"
OpName %a "a"
OpName %gl_FragCoord "gl_FragCoord"
OpName %buf0 "buf0"
OpMemberName %buf0 0 "_GLF_uniform_float_values"
OpName %__0 ""
OpName %_GLF_color "_GLF_color"
OpDecorate %_arr_int_uint_3 ArrayStride 16
OpMemberDecorate %buf1 0 Offset 0
OpDecorate %buf1 Block
OpDecorate %_ DescriptorSet 0
OpDecorate %_ Binding 1
OpDecorate %gl_FragCoord BuiltIn FragCoord
OpDecorate %_arr_float_uint_1 ArrayStride 16
OpMemberDecorate %buf0 0 Offset 0
OpDecorate %buf0 Block
OpDecorate %__0 DescriptorSet 0
OpDecorate %__0 Binding 0
OpDecorate %_GLF_color Location 0
%void = OpTypeVoid
%15 = OpTypeFunction %void
%int = OpTypeInt 32 1
%_ptr_Function_int = OpTypePointer Function %int
%uint = OpTypeInt 32 0
%uint_3 = OpConstant %uint 3
%_arr_int_uint_3 = OpTypeArray %int %uint_3
%buf1 = OpTypeStruct %_arr_int_uint_3
%_ptr_Uniform_buf1 = OpTypePointer Uniform %buf1
%_ = OpVariable %_ptr_Uniform_buf1 Uniform
%int_0 = OpConstant %int 0
%_ptr_Uniform_int = OpTypePointer Uniform %int
%int_2 = OpConstant %int 2
%bool = OpTypeBool
%uint_2 = OpConstant %uint 2
%_arr_int_uint_2 = OpTypeArray %int %uint_2
%_ptr_Function__arr_int_uint_2 = OpTypePointer Function %_arr_int_uint_2
%int_1 = OpConstant %int 1
%int_n1 = OpConstant %int -1
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Input_v4float = OpTypePointer Input %v4float
%gl_FragCoord = OpVariable %_ptr_Input_v4float Input
%uint_1 = OpConstant %uint 1
%_ptr_Input_float = OpTypePointer Input %float
%_arr_float_uint_1 = OpTypeArray %float %uint_1
%buf0 = OpTypeStruct %_arr_float_uint_1
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%__0 = OpVariable %_ptr_Uniform_buf0 Uniform
%_ptr_Uniform_float = OpTypePointer Uniform %float
%_ptr_Output_v4float = OpTypePointer Output %v4float
%_GLF_color = OpVariable %_ptr_Output_v4float Output
%main = OpFunction %void None %15
%38 = OpLabel
%i = OpVariable %_ptr_Function_int Function
%arr = OpVariable %_ptr_Function__arr_int_uint_2 Function
%a = OpVariable %_ptr_Function_int Function
%39 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%40 = OpLoad %int %39
OpStore %i %40
OpBranch %41
%41 = OpLabel
OpLoopMerge %42 %43 None
OpBranch %44
%44 = OpLabel
%45 = OpLoad %int %i
%46 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_2
%47 = OpLoad %int %46
%48 = OpSLessThan %bool %45 %47
OpBranchConditional %48 %49 %42
%49 = OpLabel
%50 = OpLoad %int %i
%51 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%52 = OpLoad %int %51
%53 = OpAccessChain %_ptr_Function_int %arr %50
OpStore %53 %52
OpBranch %43
%43 = OpLabel
%54 = OpLoad %int %i
%55 = OpIAdd %int %54 %int_1
OpStore %i %55
OpBranch %41
%42 = OpLabel
OpStore %a %int_n1
%56 = OpAccessChain %_ptr_Input_float %gl_FragCoord %uint_1
%57 = OpLoad %float %56
%58 = OpAccessChain %_ptr_Uniform_float %__0 %int_0 %int_0
%59 = OpLoad %float %58
%60 = OpFOrdLessThan %bool %57 %59
%61 = OpLogicalNot %bool %60
OpSelectionMerge %62 None
OpBranchConditional %61 %63 %62
%63 = OpLabel
%64 = OpLoad %int %a
%65 = OpIAdd %int %64 %int_1
OpStore %a %65
%66 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_1
%67 = OpLoad %int %66
%68 = OpAccessChain %_ptr_Function_int %arr %65
OpStore %68 %67
OpBranch %62
%62 = OpLabel
%69 = OpLoad %int %a
%70 = OpIAdd %int %69 %int_1
OpStore %a %70
%71 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_2
%72 = OpLoad %int %71
%73 = OpAccessChain %_ptr_Function_int %arr %70
OpStore %73 %72
%74 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%75 = OpLoad %int %74
%76 = OpAccessChain %_ptr_Function_int %arr %75
%77 = OpLoad %int %76
%78 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_1
%79 = OpLoad %int %78
%80 = OpIEqual %bool %77 %79
OpSelectionMerge %81 None
OpBranchConditional %80 %82 %83
%82 = OpLabel
%84 = OpLoad %int %a
%85 = OpConvertSToF %float %84
%86 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%87 = OpLoad %int %86
%88 = OpConvertSToF %float %87
%89 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%90 = OpLoad %int %89
%91 = OpConvertSToF %float %90
%92 = OpLoad %int %a
%93 = OpConvertSToF %float %92
%94 = OpCompositeConstruct %v4float %85 %88 %91 %93
OpStore %_GLF_color %94
OpBranch %81
%83 = OpLabel
%95 = OpAccessChain %_ptr_Uniform_int %_ %int_0 %int_0
%96 = OpLoad %int %95
%97 = OpConvertSToF %float %96
%98 = OpCompositeConstruct %v4float %97 %97 %97 %97
OpStore %_GLF_color %98
OpBranch %81
%81 = OpLabel
OpReturn
OpFunctionEnd