1 OpCapability Shader 2 %1 = OpExtInstImport "GLSL.std.450" 3 OpMemoryModel Logical GLSL450 4 OpEntryPoint Fragment %_entrypoint_v "_entrypoint" %sk_FragColor 5 OpExecutionMode %_entrypoint_v OriginUpperLeft 6 OpName %sk_FragColor "sk_FragColor" 7 OpName %_UniformBuffer "_UniformBuffer" 8 OpMemberName %_UniformBuffer 0 "testInputs" 9 OpMemberName %_UniformBuffer 1 "colorGreen" 10 OpMemberName %_UniformBuffer 2 "colorRed" 11 OpName %_entrypoint_v "_entrypoint_v" 12 OpName %main "main" 13 OpName %uintValues "uintValues" 14 OpName %expectedA "expectedA" 15 OpName %expectedB "expectedB" 16 OpDecorate %sk_FragColor RelaxedPrecision 17 OpDecorate %sk_FragColor Location 0 18 OpDecorate %sk_FragColor Index 0 19 OpMemberDecorate %_UniformBuffer 0 Offset 0 20 OpMemberDecorate %_UniformBuffer 0 RelaxedPrecision 21 OpMemberDecorate %_UniformBuffer 1 Offset 16 22 OpMemberDecorate %_UniformBuffer 1 RelaxedPrecision 23 OpMemberDecorate %_UniformBuffer 2 Offset 32 24 OpMemberDecorate %_UniformBuffer 2 RelaxedPrecision 25 OpDecorate %_UniformBuffer Block 26 OpDecorate %7 Binding 0 27 OpDecorate %7 DescriptorSet 0 28 OpDecorate %31 RelaxedPrecision 29 OpDecorate %33 RelaxedPrecision 30 OpDecorate %36 RelaxedPrecision 31 OpDecorate %37 RelaxedPrecision 32 OpDecorate %39 RelaxedPrecision 33 OpDecorate %41 RelaxedPrecision 34 OpDecorate %43 RelaxedPrecision 35 OpDecorate %177 RelaxedPrecision 36 OpDecorate %180 RelaxedPrecision 37 OpDecorate %181 RelaxedPrecision 38 %float = OpTypeFloat 32 39 %v4float = OpTypeVector %float 4 40%_ptr_Output_v4float = OpTypePointer Output %v4float 41%sk_FragColor = OpVariable %_ptr_Output_v4float Output 42%_UniformBuffer = OpTypeStruct %v4float %v4float %v4float 43%_ptr_Uniform__UniformBuffer = OpTypePointer Uniform %_UniformBuffer 44 %7 = OpVariable %_ptr_Uniform__UniformBuffer Uniform 45 %void = OpTypeVoid 46 %12 = OpTypeFunction %void 47 %float_0 = OpConstant %float 0 48 %v2float = OpTypeVector %float 2 49 %16 = OpConstantComposite %v2float %float_0 %float_0 50%_ptr_Function_v2float = OpTypePointer Function %v2float 51 %20 = OpTypeFunction %v4float %_ptr_Function_v2float 52 %uint = OpTypeInt 32 0 53 %v4uint = OpTypeVector %uint 4 54%_ptr_Function_v4uint = OpTypePointer Function %v4uint 55%_ptr_Uniform_v4float = OpTypePointer Uniform %v4float 56 %int = OpTypeInt 32 1 57 %int_0 = OpConstant %int 0 58 %float_100 = OpConstant %float 100 59 %float_200 = OpConstant %float 200 60 %35 = OpConstantComposite %v4float %float_200 %float_200 %float_200 %float_200 61 %uint_100 = OpConstant %uint 100 62 %uint_200 = OpConstant %uint 200 63 %uint_275 = OpConstant %uint 275 64 %uint_300 = OpConstant %uint 300 65 %51 = OpConstantComposite %v4uint %uint_100 %uint_200 %uint_275 %uint_300 66 %uint_250 = OpConstant %uint 250 67 %uint_425 = OpConstant %uint 425 68 %55 = OpConstantComposite %v4uint %uint_100 %uint_200 %uint_250 %uint_425 69 %bool = OpTypeBool 70 %false = OpConstantFalse %bool 71 %v2uint = OpTypeVector %uint 2 72 %66 = OpConstantComposite %v2uint %uint_100 %uint_100 73 %67 = OpConstantComposite %v2uint %uint_300 %uint_300 74 %v2bool = OpTypeVector %bool 2 75 %v3uint = OpTypeVector %uint 3 76 %78 = OpConstantComposite %v3uint %uint_100 %uint_100 %uint_100 77 %79 = OpConstantComposite %v3uint %uint_300 %uint_300 %uint_300 78 %v3bool = OpTypeVector %bool 3 79 %88 = OpConstantComposite %v4uint %uint_100 %uint_100 %uint_100 %uint_100 80 %89 = OpConstantComposite %v4uint %uint_300 %uint_300 %uint_300 %uint_300 81 %v4bool = OpTypeVector %bool 4 82 %true = OpConstantTrue %bool 83 %100 = OpConstantComposite %v2uint %uint_100 %uint_200 84 %107 = OpConstantComposite %v3uint %uint_100 %uint_200 %uint_275 85 %uint_0 = OpConstant %uint 0 86 %125 = OpConstantComposite %v2uint %uint_100 %uint_0 87 %uint_400 = OpConstant %uint 400 88 %127 = OpConstantComposite %v2uint %uint_300 %uint_400 89 %136 = OpConstantComposite %v3uint %uint_100 %uint_0 %uint_0 90 %137 = OpConstantComposite %v3uint %uint_300 %uint_400 %uint_250 91 %145 = OpConstantComposite %v4uint %uint_100 %uint_0 %uint_0 %uint_300 92 %uint_500 = OpConstant %uint 500 93 %147 = OpConstantComposite %v4uint %uint_300 %uint_400 %uint_250 %uint_500 94 %162 = OpConstantComposite %v3uint %uint_100 %uint_200 %uint_250 95%_ptr_Function_v4float = OpTypePointer Function %v4float 96 %int_1 = OpConstant %int 1 97 %int_2 = OpConstant %int 2 98%_entrypoint_v = OpFunction %void None %12 99 %13 = OpLabel 100 %17 = OpVariable %_ptr_Function_v2float Function 101 OpStore %17 %16 102 %19 = OpFunctionCall %v4float %main %17 103 OpStore %sk_FragColor %19 104 OpReturn 105 OpFunctionEnd 106 %main = OpFunction %v4float None %20 107 %21 = OpFunctionParameter %_ptr_Function_v2float 108 %22 = OpLabel 109 %uintValues = OpVariable %_ptr_Function_v4uint Function 110 %expectedA = OpVariable %_ptr_Function_v4uint Function 111 %expectedB = OpVariable %_ptr_Function_v4uint Function 112 %170 = OpVariable %_ptr_Function_v4float Function 113 %27 = OpAccessChain %_ptr_Uniform_v4float %7 %int_0 114 %31 = OpLoad %v4float %27 115 %33 = OpVectorTimesScalar %v4float %31 %float_100 116 %36 = OpFAdd %v4float %33 %35 117 %37 = OpCompositeExtract %float %36 0 118 %38 = OpConvertFToU %uint %37 119 %39 = OpCompositeExtract %float %36 1 120 %40 = OpConvertFToU %uint %39 121 %41 = OpCompositeExtract %float %36 2 122 %42 = OpConvertFToU %uint %41 123 %43 = OpCompositeExtract %float %36 3 124 %44 = OpConvertFToU %uint %43 125 %45 = OpCompositeConstruct %v4uint %38 %40 %42 %44 126 OpStore %uintValues %45 127 OpStore %expectedA %51 128 OpStore %expectedB %55 129 %59 = OpCompositeExtract %uint %45 0 130 %58 = OpExtInst %uint %1 UClamp %59 %uint_100 %uint_300 131 %60 = OpIEqual %bool %58 %uint_100 132 OpSelectionMerge %62 None 133 OpBranchConditional %60 %61 %62 134 %61 = OpLabel 135 %64 = OpVectorShuffle %v2uint %45 %45 0 1 136 %63 = OpExtInst %v2uint %1 UClamp %64 %66 %67 137 %68 = OpVectorShuffle %v2uint %51 %51 0 1 138 %69 = OpIEqual %v2bool %63 %68 139 %71 = OpAll %bool %69 140 OpBranch %62 141 %62 = OpLabel 142 %72 = OpPhi %bool %false %22 %71 %61 143 OpSelectionMerge %74 None 144 OpBranchConditional %72 %73 %74 145 %73 = OpLabel 146 %76 = OpVectorShuffle %v3uint %45 %45 0 1 2 147 %75 = OpExtInst %v3uint %1 UClamp %76 %78 %79 148 %80 = OpVectorShuffle %v3uint %51 %51 0 1 2 149 %81 = OpIEqual %v3bool %75 %80 150 %83 = OpAll %bool %81 151 OpBranch %74 152 %74 = OpLabel 153 %84 = OpPhi %bool %false %62 %83 %73 154 OpSelectionMerge %86 None 155 OpBranchConditional %84 %85 %86 156 %85 = OpLabel 157 %87 = OpExtInst %v4uint %1 UClamp %45 %88 %89 158 %90 = OpIEqual %v4bool %87 %51 159 %92 = OpAll %bool %90 160 OpBranch %86 161 %86 = OpLabel 162 %93 = OpPhi %bool %false %74 %92 %85 163 OpSelectionMerge %95 None 164 OpBranchConditional %93 %94 %95 165 %94 = OpLabel 166 OpBranch %95 167 %95 = OpLabel 168 %97 = OpPhi %bool %false %86 %true %94 169 OpSelectionMerge %99 None 170 OpBranchConditional %97 %98 %99 171 %98 = OpLabel 172 %101 = OpVectorShuffle %v2uint %51 %51 0 1 173 %102 = OpIEqual %v2bool %100 %101 174 %103 = OpAll %bool %102 175 OpBranch %99 176 %99 = OpLabel 177 %104 = OpPhi %bool %false %95 %103 %98 178 OpSelectionMerge %106 None 179 OpBranchConditional %104 %105 %106 180 %105 = OpLabel 181 %108 = OpVectorShuffle %v3uint %51 %51 0 1 2 182 %109 = OpIEqual %v3bool %107 %108 183 %110 = OpAll %bool %109 184 OpBranch %106 185 %106 = OpLabel 186 %111 = OpPhi %bool %false %99 %110 %105 187 OpSelectionMerge %113 None 188 OpBranchConditional %111 %112 %113 189 %112 = OpLabel 190 OpBranch %113 191 %113 = OpLabel 192 %114 = OpPhi %bool %false %106 %true %112 193 OpSelectionMerge %116 None 194 OpBranchConditional %114 %115 %116 195 %115 = OpLabel 196 %117 = OpExtInst %uint %1 UClamp %59 %uint_100 %uint_300 197 %118 = OpIEqual %bool %117 %uint_100 198 OpBranch %116 199 %116 = OpLabel 200 %119 = OpPhi %bool %false %113 %118 %115 201 OpSelectionMerge %121 None 202 OpBranchConditional %119 %120 %121 203 %120 = OpLabel 204 %123 = OpVectorShuffle %v2uint %45 %45 0 1 205 %122 = OpExtInst %v2uint %1 UClamp %123 %125 %127 206 %128 = OpVectorShuffle %v2uint %55 %55 0 1 207 %129 = OpIEqual %v2bool %122 %128 208 %130 = OpAll %bool %129 209 OpBranch %121 210 %121 = OpLabel 211 %131 = OpPhi %bool %false %116 %130 %120 212 OpSelectionMerge %133 None 213 OpBranchConditional %131 %132 %133 214 %132 = OpLabel 215 %135 = OpVectorShuffle %v3uint %45 %45 0 1 2 216 %134 = OpExtInst %v3uint %1 UClamp %135 %136 %137 217 %138 = OpVectorShuffle %v3uint %55 %55 0 1 2 218 %139 = OpIEqual %v3bool %134 %138 219 %140 = OpAll %bool %139 220 OpBranch %133 221 %133 = OpLabel 222 %141 = OpPhi %bool %false %121 %140 %132 223 OpSelectionMerge %143 None 224 OpBranchConditional %141 %142 %143 225 %142 = OpLabel 226 %144 = OpExtInst %v4uint %1 UClamp %45 %145 %147 227 %148 = OpIEqual %v4bool %144 %55 228 %149 = OpAll %bool %148 229 OpBranch %143 230 %143 = OpLabel 231 %150 = OpPhi %bool %false %133 %149 %142 232 OpSelectionMerge %152 None 233 OpBranchConditional %150 %151 %152 234 %151 = OpLabel 235 OpBranch %152 236 %152 = OpLabel 237 %153 = OpPhi %bool %false %143 %true %151 238 OpSelectionMerge %155 None 239 OpBranchConditional %153 %154 %155 240 %154 = OpLabel 241 %156 = OpVectorShuffle %v2uint %55 %55 0 1 242 %157 = OpIEqual %v2bool %100 %156 243 %158 = OpAll %bool %157 244 OpBranch %155 245 %155 = OpLabel 246 %159 = OpPhi %bool %false %152 %158 %154 247 OpSelectionMerge %161 None 248 OpBranchConditional %159 %160 %161 249 %160 = OpLabel 250 %163 = OpVectorShuffle %v3uint %55 %55 0 1 2 251 %164 = OpIEqual %v3bool %162 %163 252 %165 = OpAll %bool %164 253 OpBranch %161 254 %161 = OpLabel 255 %166 = OpPhi %bool %false %155 %165 %160 256 OpSelectionMerge %168 None 257 OpBranchConditional %166 %167 %168 258 %167 = OpLabel 259 OpBranch %168 260 %168 = OpLabel 261 %169 = OpPhi %bool %false %161 %true %167 262 OpSelectionMerge %174 None 263 OpBranchConditional %169 %172 %173 264 %172 = OpLabel 265 %175 = OpAccessChain %_ptr_Uniform_v4float %7 %int_1 266 %177 = OpLoad %v4float %175 267 OpStore %170 %177 268 OpBranch %174 269 %173 = OpLabel 270 %178 = OpAccessChain %_ptr_Uniform_v4float %7 %int_2 271 %180 = OpLoad %v4float %178 272 OpStore %170 %180 273 OpBranch %174 274 %174 = OpLabel 275 %181 = OpLoad %v4float %170 276 OpReturnValue %181 277 OpFunctionEnd 278