| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 0 |
| ; Bound: 53 |
| ; Schema: 0 |
| OpCapability Shader |
| OpMemoryModel Logical GLSL450 |
| OpEntryPoint Fragment %main "main" %x_2_param_1 %x_3_param_1 %x_4_1_1 |
| OpExecutionMode %main OriginUpperLeft |
| OpName %x_2_param_1 "x_2_param_1" |
| OpName %x_3_param_1 "x_3_param_1" |
| OpName %x_4_1_1 "x_4_1_1" |
| OpName %x_2 "x_2" |
| OpName %x_3 "x_3" |
| OpName %x_4 "x_4" |
| OpName %main_1 "main_1" |
| OpName %main_out "main_out" |
| OpMemberName %main_out 0 "x_4_1" |
| OpName %main_inner "main_inner" |
| OpName %x_2_param "x_2_param" |
| OpName %x_3_param "x_3_param" |
| OpName %main "main" |
| OpDecorate %x_2_param_1 BuiltIn FragCoord |
| OpDecorate %x_3_param_1 Location 0 |
| OpDecorate %x_3_param_1 Flat |
| OpDecorate %x_4_1_1 Location 0 |
| OpMemberDecorate %main_out 0 Offset 0 |
| %float = OpTypeFloat 32 |
| %v4float = OpTypeVector %float 4 |
| %_ptr_Input_v4float = OpTypePointer Input %v4float |
| %x_2_param_1 = OpVariable %_ptr_Input_v4float Input |
| %int = OpTypeInt 32 1 |
| %_ptr_Input_int = OpTypePointer Input %int |
| %x_3_param_1 = OpVariable %_ptr_Input_int Input |
| %_ptr_Output_int = OpTypePointer Output %int |
| %10 = OpConstantNull %int |
| %x_4_1_1 = OpVariable %_ptr_Output_int Output %10 |
| %_ptr_Private_v4float = OpTypePointer Private %v4float |
| %13 = OpConstantNull %v4float |
| %x_2 = OpVariable %_ptr_Private_v4float Private %13 |
| %_ptr_Private_int = OpTypePointer Private %int |
| %x_3 = OpVariable %_ptr_Private_int Private %10 |
| %x_4 = OpVariable %_ptr_Private_int Private %10 |
| %void = OpTypeVoid |
| %17 = OpTypeFunction %void |
| %int_1 = OpConstant %int 1 |
| %bool = OpTypeBool |
| %main_out = OpTypeStruct %int |
| %38 = OpTypeFunction %main_out %v4float %int |
| %main_1 = OpFunction %void None %17 |
| %20 = OpLabel |
| %21 = OpLoad %v4float %x_2 |
| %22 = OpLoad %int %x_3 |
| %24 = OpCompositeExtract %float %21 0 |
| %23 = OpConvertFToS %int %24 |
| %26 = OpBitwiseAnd %int %23 %int_1 |
| %28 = OpCompositeExtract %float %21 1 |
| %27 = OpConvertFToS %int %28 |
| %29 = OpBitwiseAnd %int %27 %int_1 |
| %30 = OpIAdd %int %26 %29 |
| %31 = OpIAdd %int %30 %22 |
| %33 = OpCompositeExtract %float %21 2 |
| %32 = OpConvertFToS %int %33 |
| %34 = OpIEqual %bool %31 %32 |
| OpSelectionMerge %36 None |
| OpBranchConditional %34 %37 %36 |
| %37 = OpLabel |
| OpBranch %36 |
| %36 = OpLabel |
| OpStore %x_4 %int_1 |
| OpReturn |
| OpFunctionEnd |
| %main_inner = OpFunction %main_out None %38 |
| %x_2_param = OpFunctionParameter %v4float |
| %x_3_param = OpFunctionParameter %int |
| %43 = OpLabel |
| OpStore %x_2 %x_2_param |
| OpStore %x_3 %x_3_param |
| %44 = OpFunctionCall %void %main_1 |
| %45 = OpLoad %int %x_4 |
| %46 = OpCompositeConstruct %main_out %45 |
| OpReturnValue %46 |
| OpFunctionEnd |
| %main = OpFunction %void None %17 |
| %48 = OpLabel |
| %50 = OpLoad %v4float %x_2_param_1 |
| %51 = OpLoad %int %x_3_param_1 |
| %49 = OpFunctionCall %main_out %main_inner %50 %51 |
| %52 = OpCompositeExtract %int %49 0 |
| OpStore %x_4_1_1 %52 |
| OpReturn |
| OpFunctionEnd |