blob: 144e5796df8ef4bd4ff9bc2594439c536fd102f5 [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 60
; Schema: 0
OpCapability Shader
%40 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %x_GLF_color_1_1
OpExecutionMode %main OriginUpperLeft
OpName %x_GLF_color_1_1 "x_GLF_color_1_1"
OpName %buf0 "buf0"
OpMemberName %buf0 0 "one"
OpName %x_7 "x_7"
OpName %x_GLF_color "x_GLF_color"
OpName %main_1 "main_1"
OpName %v "v"
OpName %res "res"
OpName %main_out "main_out"
OpMemberName %main_out 0 "x_GLF_color_1"
OpName %main_inner "main_inner"
OpName %main "main"
OpDecorate %x_GLF_color_1_1 Location 0
OpDecorate %buf0 Block
OpMemberDecorate %buf0 0 Offset 0
OpDecorate %x_7 NonWritable
OpDecorate %x_7 DescriptorSet 0
OpDecorate %x_7 Binding 0
OpMemberDecorate %main_out 0 Offset 0
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Output_v4float = OpTypePointer Output %v4float
%5 = OpConstantNull %v4float
%x_GLF_color_1_1 = OpVariable %_ptr_Output_v4float Output %5
%buf0 = OpTypeStruct %float
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_7 = OpVariable %_ptr_Uniform_buf0 Uniform
%_ptr_Private_v4float = OpTypePointer Private %v4float
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %5
%void = OpTypeVoid
%11 = OpTypeFunction %void
%_ptr_Function_v4float = OpTypePointer Function %v4float
%float_8_39999962 = OpConstant %float 8.39999962
%float_n864_664978 = OpConstant %float -864.664978
%float_945_419983 = OpConstant %float 945.419983
%float_1 = OpConstant %float 1
%22 = OpConstantComposite %v4float %float_8_39999962 %float_n864_664978 %float_945_419983 %float_1
%uint = OpTypeInt 32 0
%uint_0 = OpConstant %uint 0
%_ptr_Uniform_float = OpTypePointer Uniform %float
%mat4v4float = OpTypeMatrix %v4float 4
%float_0 = OpConstant %float 0
%float_0_00999999978 = OpConstant %float 0.00999999978
%bool = OpTypeBool
%47 = OpConstantComposite %v4float %float_1 %float_0 %float_0 %float_1
%48 = OpConstantComposite %v4float %float_0 %float_0 %float_0 %float_0
%main_out = OpTypeStruct %v4float
%49 = OpTypeFunction %main_out
%main_1 = OpFunction %void None %11
%14 = OpLabel
%v = OpVariable %_ptr_Function_v4float Function %5
%res = OpVariable %_ptr_Function_v4float Function %5
OpStore %v %22
%26 = OpAccessChain %_ptr_Uniform_float %x_7 %uint_0
%27 = OpLoad %float %26
%28 = OpLoad %v4float %v
%31 = OpCompositeConstruct %v4float %27 %float_0 %float_0 %float_0
%32 = OpCompositeConstruct %v4float %float_0 %27 %float_0 %float_0
%33 = OpCompositeConstruct %v4float %float_0 %float_0 %27 %float_0
%34 = OpCompositeConstruct %v4float %float_0 %float_0 %float_0 %27
%35 = OpCompositeConstruct %mat4v4float %31 %32 %33 %34
%36 = OpMatrixTimesVector %v4float %35 %28
OpStore %res %36
%37 = OpLoad %v4float %v
%38 = OpLoad %v4float %res
%39 = OpExtInst %float %40 Distance %37 %38
%42 = OpFOrdLessThan %bool %39 %float_0_00999999978
OpSelectionMerge %44 None
OpBranchConditional %42 %45 %46
%45 = OpLabel
OpStore %x_GLF_color %47
OpBranch %44
%46 = OpLabel
OpStore %x_GLF_color %48
OpBranch %44
%44 = OpLabel
OpReturn
OpFunctionEnd
%main_inner = OpFunction %main_out None %49
%52 = OpLabel
%53 = OpFunctionCall %void %main_1
%54 = OpLoad %v4float %x_GLF_color
%55 = OpCompositeConstruct %main_out %54
OpReturnValue %55
OpFunctionEnd
%main = OpFunction %void None %11
%57 = OpLabel
%58 = OpFunctionCall %main_out %main_inner
%59 = OpCompositeExtract %v4float %58 0
OpStore %x_GLF_color_1_1 %59
OpReturn
OpFunctionEnd