Files
metal2vulkan/docs
Anees Iqbal 5983bb3e72 RUNTIME 2324: Boxed draws: a fanned-out triangle's geometry stage is worth 24 vertex-regions, not 180
The boxing rule (RUNTIME 2318) took GEOMETRY_TRIANGLE_WORK = 180 from the pieces
lane's bands frame, whose 22-by-10-pixel triangles cost 132 ns each fanned out on
an Iris Xe: mostly their fragments, which every route shades, not the geometry
stage boxing saves. Its 61 boxes on the patches frame (2-pixel quads, about 18
regions a box) lost on every device measured, the pass's warm piece:
  Iris Xe (Mesa 26.2.6)    4.64 ms fanned, 9.21 / 9.06 ms boxed  (m3-max-30553)
  Radeon 780M (Mesa)       6.47 / 6.46 ms, 13.57 / 13.57 ms      (m3-max-30687)
  RTX 3090 (620.70.06)     2.80 / 2.77 ms, 3.01 / 3.00 ms        (m3-max-30686)
On that frame, whose fragments cost little, a fanned-out triangle cost 15.4,
21.5 and 9.3 ns, a boxed vertex-region 0.59, 0.87 and 0.19 ns: 26, 25 and 49
units. The constant is the least, 24.7, rounded down, so a draw it boxes costs
no more than its fan-out on each of the three; a lower constant only boxes
fewer draws than 180 did. The doc and docs/FAST-PATHS.md's row carry the numbers.

tests::rate_mapped_boxed_draws: the 120-by-40 strip across ten regions (50
units a triangle, the patches frame's boxes about 55) is now fanned out, and a
patch across four regions' corner is boxed in its place, so the test still
boxes a draw across region borders: counts [1, 0, 3, 4, 4]. At 180 the strip is
boxed and the counts fail. tests::rate_mapped_boxed_rule checks the rule on the
patches frame's average draw: 18 regions fanned out, 4 boxed. The lane's patches
frame no longer asserts that it boxes a draw.

RUNTIME 2324: an unchanged artifact's rate-mapped draw that boxed at 180 fans out at 24.
2026-11-14 17:37:51 -08:00
..