blob: 673f4598fcc8b4da28f86ef3b4d699cddb9529b9 [file] [log] [blame]
warning: use of deprecated intrinsic
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 41
; Schema: 0
OpCapability Shader
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %main "main" %gl_FragCoord_param_1 %color_out_1_1
OpExecutionMode %main OriginUpperLeft
OpName %gl_FragCoord_param_1 "gl_FragCoord_param_1"
OpName %color_out_1_1 "color_out_1_1"
OpName %color_out "color_out"
OpName %texture "texture"
OpName %gl_FragCoord "gl_FragCoord"
OpName %main_1 "main_1"
OpName %main_out "main_out"
OpMemberName %main_out 0 "color_out_1"
OpName %main_inner "main_inner"
OpName %gl_FragCoord_param "gl_FragCoord_param"
OpName %main "main"
OpDecorate %gl_FragCoord_param_1 BuiltIn FragCoord
OpDecorate %color_out_1_1 Location 0
OpDecorate %texture NonWritable
OpDecorate %texture DescriptorSet 0
OpDecorate %texture Binding 0
OpMemberDecorate %main_out 0 Offset 0
%float = OpTypeFloat 32
%v4float = OpTypeVector %float 4
%_ptr_Input_v4float = OpTypePointer Input %v4float
%gl_FragCoord_param_1 = OpVariable %_ptr_Input_v4float Input
%_ptr_Output_v4float = OpTypePointer Output %v4float
%7 = OpConstantNull %v4float
%color_out_1_1 = OpVariable %_ptr_Output_v4float Output %7
%_ptr_Private_v4float = OpTypePointer Private %v4float
%color_out = OpVariable %_ptr_Private_v4float Private %7
%12 = OpTypeImage %float 2D 0 0 0 2 Rgba8
%_ptr_UniformConstant_12 = OpTypePointer UniformConstant %12
%texture = OpVariable %_ptr_UniformConstant_12 UniformConstant
%gl_FragCoord = OpVariable %_ptr_Private_v4float Private %7
%void = OpTypeVoid
%14 = OpTypeFunction %void
%int = OpTypeInt 32 1
%v2int = OpTypeVector %int 2
%v2float = OpTypeVector %float 2
%main_out = OpTypeStruct %v4float
%28 = OpTypeFunction %main_out %v4float
%main_1 = OpFunction %void None %14
%17 = OpLabel
%18 = OpLoad %v4float %gl_FragCoord
%20 = OpLoad %12 %texture
%25 = OpCompositeExtract %float %18 0
%26 = OpCompositeExtract %float %18 1
%27 = OpCompositeConstruct %v2float %25 %26
%21 = OpConvertFToS %v2int %27
%19 = OpImageRead %v4float %20 %21
OpStore %color_out %19
OpReturn
OpFunctionEnd
%main_inner = OpFunction %main_out None %28
%gl_FragCoord_param = OpFunctionParameter %v4float
%32 = OpLabel
OpStore %gl_FragCoord %gl_FragCoord_param
%33 = OpFunctionCall %void %main_1
%34 = OpLoad %v4float %color_out
%35 = OpCompositeConstruct %main_out %34
OpReturnValue %35
OpFunctionEnd
%main = OpFunction %void None %14
%37 = OpLabel
%39 = OpLoad %v4float %gl_FragCoord_param_1
%38 = OpFunctionCall %main_out %main_inner %39
%40 = OpCompositeExtract %v4float %38 0
OpStore %color_out_1_1 %40
OpReturn
OpFunctionEnd