Build the tiled texture buffer of two levels past the descriptor's check in its planner test

The descriptor's own check stops a texture buffer of more than one level before
the buffer's plan sees it (RuntimeGap::TextureBufferLevels), so the case
panicked in the helper on the M3 (potluck m3-max-7540). The test now takes the
checked one-level layout and sets two levels, which the plan stops as
MipmapLevelCount.

Verified: the device run that follows.
(cherry picked from commit ec197cff3e0d414fe4a5524b40391cc1ff5e9318)
This commit is contained in:
Anees Iqbal committed 2026-11-08 00:39:19 -08:00
1 parent 7205978cfa
commit 513e323884
1 file changed
+6 -2
@@ -401,9 +401,13 @@ fn a_tiled_texture_takes_levels_over_the_buffer_s_rows() {
row_bytes: 32,
})
);
// A texture buffer has one level, at an offset of 16 bytes' multiple.
// A texture buffer has one level (the descriptor's check stops two before the buffer's plan
// here, which holds them to one), at an offset of 16 bytes' multiple.
let mut two = buffer_texture(tiled(1, texture_buffer(64, 0, 256, 4096)));
two.layout.levels = 2;
let facts = BufferFacts { length: 4096 };
assert_eq!(
plan(tiled(2, texture_buffer(64, 0, 256, 4096))),
plan_buffer_texture(&two, &facts).map(|placed| placed.gpu),
refused(Pr::MipmapLevelCount { count: 2 })
);
assert_eq!(