Selection summed a word cost per strategy and per interface part into a `SizeEstimate` and refused
the function `LimitExceeded(SpirvWords)` before emission when the sum passed the cap. The sum was a
forecast, not a bound, and it overshot: a guest kernel (function hash 4cc9c0bb, Iris profile, on
the command-line path) estimated 30,197,397 words against the 16,777,216 cap and emits 8,589,684
(job 62553), so it was
refused for a size it does not have. The cap already held exactly on the serialized module; that
check is now the only one (`pipeline::compile::lower_bounded`). That kernel is now refused by what
it holds, `LedgerBytes` at 450 MiB; a function the estimate overshot that fits the ledger can now
translate (none in this library does).
Removed with the estimate, as nothing else read them:
- `lower::estimate` (`SizeEstimate` and its frame costs), `Plan::estimate`, the check in
`stage_bound::emit` (which no longer takes the cap) and the selection's block count;
- the word sums that fed only the estimate: the stage interface's (`StageIoPlan::words`, its
parameter, object, store and rounding costs, and the fragment family's input attachments,
discards, interlock, sample loop, snapshots, imageblock, storage form, shader stencil, logic
operation, blends and word merges), the tessellation and mesh interfaces', the dispatch forms',
a module blob's, the tile staging's, and the emulated tier's and the predicated walk's extra
words, with `Predication::reloads`;
- the predicated walk's second structurization before emission, which only measured its
constructs for the estimate (`structurize::emit::construct_words`).
The per-strategy costs and shared-routine costs the `StrategyCensus` reports stay.
Public: `EntryPlan::estimated_words` goes. The consumer's checkout (reims-vgpu at 44d738908a) has 0
hits for `estimated_words` and for `EntryPlan`. `tests/api_signatures.tsv` loses that one row;
`tests/api_surface.rs`'s pinned names do not move (`EntryPlan` stays).
Tests: the checks that the estimate bounds the emitted words go from the tests that also check
something else; the tests that checked only that go (every stage, simd, leaf, tail, coordinate,
bicubic, snapshot, pulled-fetch and shared-switch entry's estimate, the large predicated body under
a multiple of its words, and the skeleton's estimate bound). The word cap's test keeps both sides
on the emitted words: a module compiles at a cap of its own words and is refused one word below.
SEMANTICS 2253: a function the estimate refused can now translate, and the refusal of one that
does not fit names the ledger. docs/REFUSALS.md regenerated: `SpirvWords` has the one site.
Verified:
- The gate on this change over f3f661dd14 (job 62796): fmt, the API signatures, clippy plain,
--cfg m2v_gpu and --cfg m2v_cpu_icd, workspace Rustdoc and doctests green; nextest of
metal2vulkan and metal2vulkan-runtime 3464 of 3468, the four reds development's own suites show
at f3f661dd14 (m3-max-62774): the old render descriptor key, which hashes SEMANTICS_VERSION,
and the new icb_indexed_extras fixture's golden cells, AIR printout and inventory part, all
blessed on development.
- Every kernel of the guest library (63, by hash), on the command-line path: intel-irisxe-anv's
runtime-policy device file, the release command line before (fe1e8780a2) and with this change
over it, alternately per kernel on one node (job 62742). 62 keep their outcome and their
output's hash; the one difference is 4cc9c0bb, refused SpirvWords before and LedgerBytes after.
It is the slowest row and the largest peak on both sides: 2.55 s and 309 MiB before, 2.86 s and
470 MiB after (it now runs into emission before the ledger refuses it). Total wall 12.0 s
before, 12.3 s after.