blob: bb87b2028b2b703793a1fae4de3d07621bf1423e [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 105
; Schema: 0
OpCapability Shader
%59 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %tint_symbol_1
OpExecutionMode %main OriginUpperLeft
OpName %buf1 "buf1"
OpMemberName %buf1 0 "x_GLF_uniform_float_values"
OpName %x_7 "x_7"
OpName %buf0 "buf0"
OpMemberName %buf0 0 "x_GLF_uniform_int_values"
OpName %x_9 "x_9"
OpName %x_GLF_color "x_GLF_color"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %main_1 "main_1"
OpName %f "f"
OpName %arr "arr"
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 %buf1 Block
OpMemberDecorate %buf1 0 Offset 0
OpDecorate %_arr_float_uint_2 ArrayStride 16
OpDecorate %x_7 NonWritable
OpDecorate %x_7 DescriptorSet 0
OpDecorate %x_7 Binding 1
OpDecorate %buf0 Block
OpMemberDecorate %buf0 0 Offset 0
OpDecorate %_arr_int_uint_4 ArrayStride 16
OpDecorate %x_9 NonWritable
OpDecorate %x_9 DescriptorSet 0
OpDecorate %x_9 Binding 0
OpDecorate %tint_symbol_1 Location 0
OpDecorate %_arr_float_uint_10 ArrayStride 4
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
%buf1 = OpTypeStruct %_arr_float_uint_2
%_ptr_Uniform_buf1 = OpTypePointer Uniform %buf1
%x_7 = OpVariable %_ptr_Uniform_buf1 Uniform
%int = OpTypeInt 32 1
%uint_4 = OpConstant %uint 4
%_arr_int_uint_4 = OpTypeArray %int %uint_4
%buf0 = OpTypeStruct %_arr_int_uint_4
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_9 = OpVariable %_ptr_Uniform_buf0 Uniform
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%17 = OpConstantNull %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %17
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_1 = OpVariable %_ptr_Output_v4float Output %17
%void = OpTypeVoid
%20 = OpTypeFunction %void
%_ptr_Function_float = OpTypePointer Function %float
%26 = OpConstantNull %float
%uint_10 = OpConstant %uint 10
%_arr_float_uint_10 = OpTypeArray %float %uint_10
%_ptr_Function__arr_float_uint_10 = OpTypePointer Function %_arr_float_uint_10
%31 = OpConstantNull %_arr_float_uint_10
%float_2 = OpConstant %float 2
%uint_0 = OpConstant %uint 0
%int_0 = OpConstant %int 0
%_ptr_Uniform_float = OpTypePointer Uniform %float
%int_1 = OpConstant %int 1
%_ptr_Uniform_int = OpTypePointer Uniform %int
%int_3 = OpConstant %int 3
%bool = OpTypeBool
%int_2 = OpConstant %int 2
%main_out = OpTypeStruct %v4float
%93 = OpTypeFunction %void %main_out
%main_1 = OpFunction %void None %20
%23 = OpLabel
%f = OpVariable %_ptr_Function_float Function %26
%arr = OpVariable %_ptr_Function__arr_float_uint_10 Function %31
OpStore %f %float_2
%36 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%37 = OpLoad %float %36
%38 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%39 = OpLoad %float %38
%40 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%41 = OpLoad %float %40
%42 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%43 = OpLoad %float %42
%44 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%45 = OpLoad %float %44
%46 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%47 = OpLoad %float %46
%48 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%49 = OpLoad %float %48
%50 = OpLoad %float %f
%52 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_1
%53 = OpLoad %float %52
%54 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%55 = OpLoad %float %54
%56 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0 %int_0
%57 = OpLoad %float %56
%58 = OpExtInst %float %59 Pow %50 %53
%60 = OpCompositeConstruct %_arr_float_uint_10 %37 %39 %41 %43 %45 %47 %49 %58 %55 %57
OpStore %arr %60
%62 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_0
%63 = OpLoad %int %62
%64 = OpAccessChain %_ptr_Function_float %arr %63
%65 = OpLoad %float %64
%67 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_3
%68 = OpLoad %int %67
%69 = OpConvertFToS %int %65
%70 = OpIEqual %bool %69 %68
OpSelectionMerge %72 None
OpBranchConditional %70 %73 %74
%73 = OpLabel
%75 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_1
%76 = OpLoad %int %75
%78 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_2
%79 = OpLoad %int %78
%80 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_2
%81 = OpLoad %int %80
%82 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_1
%83 = OpLoad %int %82
%84 = OpConvertSToF %float %76
%85 = OpConvertSToF %float %79
%86 = OpConvertSToF %float %81
%87 = OpConvertSToF %float %83
%88 = OpCompositeConstruct %v4float %84 %85 %86 %87
OpStore %x_GLF_color %88
OpBranch %72
%74 = OpLabel
%89 = OpAccessChain %_ptr_Uniform_int %x_9 %uint_0 %int_2
%90 = OpLoad %int %89
%91 = OpConvertSToF %float %90
%92 = OpCompositeConstruct %v4float %91 %91 %91 %91
OpStore %x_GLF_color %92
OpBranch %72
%72 = OpLabel
OpReturn
OpFunctionEnd
%tint_symbol_2 = OpFunction %void None %93
%tint_symbol = OpFunctionParameter %main_out
%97 = OpLabel
%98 = OpCompositeExtract %v4float %tint_symbol 0
OpStore %tint_symbol_1 %98
OpReturn
OpFunctionEnd
%main = OpFunction %void None %20
%100 = OpLabel
%101 = OpFunctionCall %void %main_1
%103 = OpLoad %v4float %x_GLF_color
%104 = OpCompositeConstruct %main_out %103
%102 = OpFunctionCall %void %tint_symbol_2 %104
OpReturn
OpFunctionEnd