| ; SPIR-V | |
| ; Version: 1.3 | |
| ; Generator: Google Tint Compiler; 1 | |
| ; Bound: 29 | |
| ; Schema: 0 | |
| OpCapability Shader | |
| OpCapability ImageQuery | |
| %20 = OpExtInstImport "GLSL.std.450" | |
| OpMemoryModel Logical GLSL450 | |
| OpEntryPoint Fragment %fs "fs" | |
| OpExecutionMode %fs OriginUpperLeft | |
| OpName %sampled_textures "sampled_textures" | |
| OpName %fs "fs" | |
| OpName %texture_load "texture_load" | |
| OpDecorate %sampled_textures DescriptorSet 0 | |
| OpDecorate %sampled_textures Binding 0 | |
| %float = OpTypeFloat 32 | |
| %4 = OpTypeImage %float 2D 0 0 0 1 Unknown | |
| %uint = OpTypeInt 32 0 | |
| %uint_4 = OpConstant %uint 4 | |
| %_arr_4_uint_4 = OpTypeArray %4 %uint_4 | |
| %_ptr_UniformConstant__arr_4_uint_4 = OpTypePointer UniformConstant %_arr_4_uint_4 | |
| %sampled_textures = OpVariable %_ptr_UniformConstant__arr_4_uint_4 UniformConstant | |
| %void = OpTypeVoid | |
| %10 = OpTypeFunction %void | |
| %_ptr_UniformConstant_4 = OpTypePointer UniformConstant %4 | |
| %uint_0 = OpConstant %uint 0 | |
| %uint_1 = OpConstant %uint 1 | |
| %v2uint = OpTypeVector %uint 2 | |
| %24 = OpConstantComposite %v2uint %uint_1 %uint_1 | |
| %26 = OpConstantNull %v2uint | |
| %v4float = OpTypeVector %float 4 | |
| %fs = OpFunction %void None %10 | |
| %11 = OpLabel | |
| %12 = OpAccessChain %_ptr_UniformConstant_4 %sampled_textures %uint_0 | |
| %15 = OpLoad %4 %12 None | |
| %16 = OpImageQueryLevels %uint %15 | |
| %17 = OpISub %uint %16 %uint_1 | |
| %19 = OpExtInst %uint %20 UMin %uint_0 %17 | |
| %21 = OpImageQuerySizeLod %v2uint %15 %19 | |
| %23 = OpISub %v2uint %21 %24 | |
| %25 = OpExtInst %v2uint %20 UMin %26 %23 | |
| %texture_load = OpImageFetch %v4float %15 %25 Lod %19 | |
| OpReturn | |
| OpFunctionEnd |