| SKIP: FAILED |
| |
| |
| @group(0) @binding(0) var sampled_textures : binding_array<texture_2d<f32>, 4>; |
| |
| @fragment |
| fn fs() { |
| do_texture_load(sampled_textures[0]); |
| } |
| |
| fn do_texture_load(t : texture_2d<f32>) { |
| let texture_load = textureLoad(t, vec2(0, 0), 0); |
| } |
| |
| Failed to generate SPIR-V: :22:135 error: access: result of access chain is type 'ptr<handle, texture_2d<f32>, read>' but instruction type is 'ptr<handle, spirv.image<f32, 2d, not_depth, non_arrayed, single_sampled, sampling_compatible, undefined, read_write>, read>' |
| %15:ptr<handle, spirv.image<f32, 2d, not_depth, non_arrayed, single_sampled, sampling_compatible, undefined, read_write>, read> = access %sampled_textures, 0i |
| ^^^^^^ |
| |
| :21:3 note: in block |
| $B3: { |
| ^^^ |
| |
| note: # Disassembly |
| $B1: { # root |
| %sampled_textures:ptr<handle, binding_array<texture_2d<f32>, 4>, read> = var undef @binding_point(0, 0) |
| } |
| |
| %do_texture_load = func(%t:spirv.image<f32, 2d, not_depth, non_arrayed, single_sampled, sampling_compatible, undefined, read_write>):void { |
| $B2: { |
| %4:u32 = spirv.image_query_levels<u32> %t |
| %5:u32 = sub %4, 1u |
| %6:u32 = convert 0i |
| %7:u32 = min %6, %5 |
| %8:vec2<u32> = spirv.image_query_size_lod %t, %7 |
| %9:vec2<u32> = sub %8, vec2<u32>(1u) |
| %10:vec2<u32> = convert vec2<i32>(0i) |
| %11:vec2<u32> = min %10, %9 |
| %12:vec4<f32> = spirv.image_fetch %t, %11, 2u, %7 |
| %texture_load:vec4<f32> = let %12 |
| ret |
| } |
| } |
| %fs = @fragment func():void { |
| $B3: { |
| %15:ptr<handle, spirv.image<f32, 2d, not_depth, non_arrayed, single_sampled, sampling_compatible, undefined, read_write>, read> = access %sampled_textures, 0i |
| %16:spirv.image<f32, 2d, not_depth, non_arrayed, single_sampled, sampling_compatible, undefined, read_write> = load %15 |
| %17:void = call %do_texture_load, %16 |
| ret |
| } |
| } |
| |
| |
| tint executable returned error: exit status 1 |