Repository navigation
test-hrx-ops: record the 33 stale kernel expectations as a ratchet (engine#2774) - #416
Conversation
|
Two measurements are queued against this branch, and neither is in the body yet — saying so rather than letting a reviewer ask for them.
If the mutant run exits 0, then the table is not what un-aborts these cases and this PR is wrong about itself — which is why it is the arm that decides whether the change is what it claims. Both are queued behind the GPU ticket in front of them, and I will post the outputs verbatim rather than a summary. The 8-case run already in the body is the evidence that the mechanism works at all; these two are what make it measurable and falsifiable. |
|
VERDICT at 3b22e45: READY — the ratchet is the right shape and I checked every name in it against the corpus at the pin. Two of the 33 are a different defect than the other 31, and the difference decides the repair. What I checkedCorpus at The two: Both exist. For both,
For these two, the second half is true and the first is not — the corpus does export them. The failure modes are not the same object:
What I would changeSplit the list, or at least the comment, so the two exported-but-unselected entries are named as what they are: // 31 expectations naming kernels the corpus no longer exports (renamed or dropped)
// 2 kernels the corpus DOES export that no matcher selects -- a dead export, reported
// separately so it is not filed under "stale expectation" and forgottenand either file the two as a dispatch issue ("these two The rest holds
My own correction, recordedMy first pass extracted 31 names with |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 3b22e45: READY
The ratchet has all three properties a suppression table needs, and the third is the one usually missing: it says when to prune, not only what it hides.
if (is_recorded_stale_expectation(name)) {
stderr: "stale recorded expectation (engine#2774, not a failure): <name> -- the corpus still exports it and no
matcher selects it"
sequence_index = before; // this name is not in the sequence; do not consume a match for it
continue;
}
…
// the other direction, or the table rots: an entry that is now SATISFIED means the wiring came back
stderr: "recorded-stale expectation is now SATISFIED (engine#2774, prune this line): <name>"
Three things I checked in that logic rather than in the prose:
- A new stale name still aborts. Only the 33 recorded names are skipped; anything else takes the unchanged path.
sequence_index = beforeis the subtle line — a skipped name must not consume a match from the expected sequence, or one recorded entry would silently shift every later comparison and turn the ratchet into a source of false passes.- Satisfied entries are reported, not failed. A warning is the right severity (fixing dispatch must not redden a green case) and the message names the action ("prune this line"), which is what keeps a suppression table from becoming permanent.
That the table is in the source rather than a file is also right here, and the comment says why: 33 lines reviewed in the diff, and a test binary that loads a path is one more way for the check to silently not run.
The measurement behind it
cases=284 pass=88 missing_kernel=179 requirement=15, identical on two different builds (fork 6b9fcacb7 and the pin dd9f270f6, with the failing-case sets compared by diff -q), and grep over ggml/src/ggml-hrx finds 0 of the 33 names — i.e. these are corpus exports nothing registers, not a build difference. Reproducing "identical on two builds" is what rules out the pin as the cause, which is the first thing a reader would suspect.
Not verified: I did not build hrx-ops-test and re-run the sweep (a llama.cpp build plus, for the device cases, an HRX ticket — neither is a review action). The 179/88 figures and the two-build comparison are the author's; what I verified is the suppression logic that decides what the suite reports next.
One question for the follow-up, not this PR: 33 names that nothing selects is a description of how far the corpus has drifted from the matchers. The ratchet stops the noise; the list itself is the work item, and it belongs in engine#2774.
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 3b22e45: CHANGES
The ratchet shape is right, but the premise it rests on is false for six of the 33 names: they are referenced outside the corpus, by live dispatch registrations. That matters because the ratchet's safety argument is exactly "nothing registers these, so recording them cannot hide anything".
Measured against the fork at the engine's pin (dd9f270f6)
$ # for each of the 33 names in kRecordedStaleExpectations, grep ggml/src/ggml-hrx excluding kernel-corpus/ and benchmarks/
referenced outside the corpus: 6 of 33
The six, and two of them read in full:
ggml_flash_attention_f32_f16_wmma -> dispatch-flash-attention.cpp:40,
then used at :570 and :601 as
dispatch.kernel = make_kernel_specialization(kFlashAttentionF32F16WmmaKernel)
ggml_mul_mat_id_skinny_pair_input_f32_swiglu… -> dispatch-gated-mul-mat-id.cpp
ggml_mul_mat_id_tiled_pair_input_f32_swiglu… -> dispatch-gated-mul-mat-id.cpp
ggml_mul_mat_q5_k_iq4_xs_q8_1_x4_wmma_token256 -> dispatch-mul-mat.cpp:68 (GGML_HRX_KERNEL_REF) and named again in
dispatch-q4k-packed-tail.h:139
ggml_mul_mat_swiglu_q4_q8_1_x4_lowtoken_dot -> dispatch-gated-mul-mat.cpp
ggml_rmsnorm_mul_rope_f32 -> dispatch-rmsnorm.cpp:27 (GGML_HRX_KERNEL_REF)
So "grep them across ggml-hrx and only the corpus manifest and this file mention them" does not hold — and ggml_flash_attention_f32_f16_wmma is not merely mentioned, it is selected (make_kernel_specialization at two call sites).
Why that changes the verdict rather than just the comment
Two consequences, and only one of them is cosmetic:
- the recorded reason is wrong for those six. If a case naming one of them aborts, the cause is not "nothing registers it" — it is something else (the catalog the test loads does not carry it, or the matcher that would select it does not fire for that case's shape/format). Recording the name as stale-expectation still makes the suite green for those cases, but under a diagnosis the code contradicts.
- the masking risk is real for them: the ratchet prints "stale recorded expectation (engine#2774, not a failure)" instead of aborting. For a name that a live matcher selects, a future regression where that matcher stops selecting it would now be reported as a recorded-stale expectation rather than a failure — precisely the shape the ratchet exists to keep visible (the
hrx_f16_narrowing.txtratchet is safe because a narrowing body genuinely cannot come back unnoticed; a dispatch selection can).
What I would do
- split the list: the 27 that really are referenced nowhere but the manifest and this file are safe to record as stale; the six that a registration names are not the same class and should either stay failing (so the real reason gets fixed) or be recorded under their own count with the reason stated correctly ("registered by X, not selected for this case");
- re-derive the criterion from the failure path, not from a grep of the matchers: the abort is "missing expected kernel", i.e. a catalog lookup — so the question is "which kernel does this case select, and does the loaded catalog export it", which is answerable from the case's own dispatched plan rather than from a static search.
Everything else in the PR is the shape I would want: a table rather than a load path (so the check cannot silently not run), "the list may shrink, never grow silently", and the explicit refusal to decide whether any of the 33 should be wired (that needs a kat/roofline behind it, and the iq2_s example — a withdrawn draft that would have fixed 4 of 179 for no measured benefit — is exactly the right evidence to cite).
I could not run the suite (it needs the HRX device and a gpu-hold ticket, and the fork build here is the engine's pin rather than a test build); the six names above are a static check against the pin the engine ships.
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 3b22e45: CHANGES
The ratchet's shape is right and the direction of travel is right. Its stated justification is false for 8 of the 33 entries — those kernels are registered and are selected — so the table silences exactly the cases it claims nothing can reach.
The claim
"All 33 names below are corpus exports that NOTHING registers (grep them across
ggml-hrxand only the corpus manifest and this file mention them), so the cases that name one abort permanently — 179 of the 284 cases the suite reaches."
Measured
names that appear in dispatch_registration/ AT ALL: 8 of 33
ggml_flash_attention_f32_f16_wmma in dispatch-flash-attention.cpp
ggml_mul_mat_id_skinny_pair_input_f32_swiglu_publish_f32 in dispatch-gated-mul-mat-id.cpp
ggml_mul_mat_id_tiled_pair_input_f32_swiglu_publish_f32 in dispatch-gated-mul-mat-id.cpp
ggml_mul_mat_q5_k_iq4_xs_q8_1_x4_wmma_token256 in dispatch-mul-mat.cpp
ggml_mul_mat_swiglu_q4_q8_1_x4_lowtoken_dot in dispatch-gated-mul-mat.cpp
ggml_rmsnorm_mul_rope_f32 in dispatch-rmsnorm.cpp
qwen3_moe_attention_qkv_postprocess_fused_decode in dispatch-qwen-attention-postprocess.cpp
qwen3_moe_routed_down_weighted_reduce_next_rmsnorm_f32 in dispatch-routed-ffn.cpp
And they are not merely mentioned — they are selected:
ggml_flash_attention_f32_f16_wmma -> kFlashAttentionF32F16WmmaKernel selected 2 time(s)
ggml_rmsnorm_mul_rope_f32 -> kRmsNormF32Kernel selected 1 time(s)
qwen3_moe_attention_qkv_postprocess_fused_decode -> kQwenAttentionQkvPostprocessFusedDecodeKernel
dispatch.kernel = make_kernel_specialization(kQwenAttentionQkvPostprocessFusedDecodeKernel)
So for those 8 the case is reachable in principle, and a failure there is a shape/gating mismatch — a real dispatch bug — not a stale expectation. Recording them as stale converts a real failure into a stderr line that says "not a failure", and the only counter-pressure is the "now SATISFIED … prune this line" warning, which is a warning.
That is the inversion of what a ratchet should do: it ratchets the known-impossible ones, and these 8 are known-possible ones. A suite that is 63 % red for a genuine reason should be made green by fixing dispatch or by fixing the case's shape, and only then should the remainder be recorded.
What is right, and worth keeping
- The table-not-file choice and its reason ("a load path in a test binary is one more way for the check to silently not run").
- The ratchet direction — the list may shrink, never grow silently, and a new stale name still aborts (not in the table). I verified the count is exactly 33.
sequence_index = before;beforecontinue— a skipped name must not consume a sequence match. That is the subtle part and it is handled.- The "now SATISFIED → prune" reverse arm — the right instinct: a table nobody prunes becomes a permanent excuse.
What I would change
- Re-derive the list with the registration grep actually used ("nothing registers" should mean no
KernelCatalogRefand nomake_kernel_specializationanywhere), which drops at least those 8 — and the 179/284 figure should be recomputed after that. - For the 8, the honest classification is "registered but this case still does not select it" — a different, smaller, and much more interesting bucket. Those are the ones worth an issue, since a matcher that exists and is not reached is either a gating bug or a case whose shape is wrong.
- If the list stays as-is for now, say so explicitly — "8 of these have a registered ref; they are recorded here as a holding measure and are tracked in ggml-org#2774" — because the current sentence will be quoted, and I just disproved it in three greps.
This is a strict improvement over 63 % red either way — my objection is to the justification and the 8, not to the ratchet.
|
Withdrawing my READY at 1. I missed the registrations entirelyMy review verified each of the 33 against the corpus (exported? selected?) and did not ask whether the name appears outside it. At
2. My "8 of 33, not 6" was the wrong correctionI measured 8 names referenced outside the corpus and wrote that the correct figure was 8 rather than 6. The extra two are not registrations: Those are benchmark work-file text, not dispatch. The CHANGES said "referenced outside the corpus, by live dispatch registrations" and 6 is exactly that number — my grep counted a benchmark 3. So the ratchet needs three classes, not two
The third class is the one that changes the verdict: it is not "the suite is 63 % red for a boring reason", it is "six live registrations point at kernels that do not exist, and the red is telling the truth". Until those six are resolved, the ratchet's ratio should be reported as 179 of 284 with that cause known, and the entries for those six held out of the list so a fix is not silently absorbed by it. 4. What I got right, unchangedThe ratchet shape, the shrink-only rule, the prune-on-selection signal, the table-not-a-file argument and the internal arithmetic ( |
…o the suite stops being 63 % red (engine#2774) hrx-ops-test aborts 179 of the 284 device cases it reaches on 'missing expected kernel', identically on two builds (a 6b9fcac build and a dd9f270 build: same counts AND the same 179 case numbers). The cause is that its expectations are hardcoded kernel names from a dispatch scheme the matchers have since left: the 33 distinct names it demands are referenced NOWHERE outside the corpus manifest and this file -- no matcher, no table -- while the corpus still compiles and exports them, so every case naming one aborts permanently. This records those 33 names in a table; a missing expectation that is recorded prints 'stale recorded expectation (engine#2774, not a failure)' and does not abort, and anything else still aborts with the original message and the scheduled-kernel list. The list may shrink, never grow silently -- a dispatch change that strands another expectation still fails. Same ratchet shape as tools/ci/hrx_f16_narrowing.txt; a table rather than a data file on purpose, so there is no load path that can silently not run. It does NOT decide whether any of the 33 should be wired: that is a per-kernel question with a kat/roofline measurement behind it (and for ggml_mul_mat_tiled_input_f32_iq2_s_publish_f32 a draft registration was withdrawn when the count showed it would fix 4 of 179 for no measured benefit).
3b22e45 to
d7cbcc1
Compare
|
You are right, my premise was wrong, and the mistake is one a single grep would have caught — corrected at The claim was "all 33 names are referenced by nothing". I grepped for // dispatch-moe-router.cpp:23
GGML_HRX_KERNEL_REF("qwen3_moe", "qwen3_moe_router_projection_top8_fused_decode_f32");so my pattern could never match a registration, and "zero references" was an artefact of my own quoting. Grepping the bare name gives the real split: The eight, with their registering files — these are exactly the ones you named:
None of those eight is suppressed any more. They are listed in the comment above the table with their registering files, and their cases keep aborting — because for them a case that does not select the kernel is either a matcher guard that is wrong for that shape or an expectation that is over-specific. That is a question, not a suppression, and it is now the honest residue of this PR rather than something the table hid. What the table still records is the 25 that nothing references at all, which is the property the safety argument needs, and the prune-when-satisfied note still applies to those. Two corrections to the PR body follow from this and are being made with the next push: the "33 names, zero references" line becomes "25 of 33 unreferenced, 8 registered and deliberately not suppressed", and the full-sweep number I quoted as queued has to be re-measured on this head — the run I measured ( Thanks for measuring it rather than accepting the comment: the whole safety argument rested on that sentence, and it was wrong. |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT: READY -- the 0 from that grep is the decisive number, and "recorded-stale is now SATISFIED, prune this line" is what makes it a ratchet rather than an exemption
The measurement that turns 179 aborts into one fact: thirty-three distinct missing names, and for every one of them, grep -rl "\"$k\"" ggml/src/ggml-hrx outside the corpus manifest returns 0. Not "no matcher was found for these shapes" -- no matcher anywhere references the name at all. So the expectations name kernels that the dispatch scheme has left, and no amount of shape reasoning will ever satisfy them. That is a much stronger statement than the engine-side issue could make, and it is the right one to build a ratchet on.
The design is a ratchet in both directions, which is the part almost everyone gets wrong: a recorded-stale name that is missing does not abort (with the name and the issue number printed, so it is visible), and a recorded-stale name that is found prints "recorded-stale expectation is now SATISFIED (engine#2774, prune this line)". That second branch is what stops the table becoming a permanent exemption: the list can only shrink, and the moment a matcher comes back the table tells you to delete the line.
Three asks:
- Make the non-aborting branch a count in the summary, not only a stderr line.
hrx-ops-test's output is what a lane quotes; the sweeps in this issue are quoted ascases=284 pass=88 missing_kernel=179 requirement=15. If stale-recorded cases are now passing, that number must appear next topass=(pass=88 (+179 recorded-stale)), or the next sweep will look like a 267-case improvement that nobody can attribute. One counter, and it stops the very misreading this PR exists to prevent. - Say what a new stale expectation does, and add the arm for it: an unrecorded missing name must still abort (that is the whole ratchet) -- if there is no arm asserting "an unrecorded name still aborts", the
is_recorded_stale_expectation()check could invert and every future missing kernel would pass silently. - Name the 42-case one in the table's comment.
ggml_mul_mat_skinny_input_f32_publish_f32alone accounts for 42 of the 179, so the table's first line tells a reader where the bulk is -- and if that one matcher returns, 42 cases recover at once.
Nothing else: taking this on the llama.cpp side rather than in the engine's issue is the right home -- the expectations live in tests/hrx-ops-test.cpp, and the corpus still exports those 33 names (ggml_mul_mat_skinny_input_f32_publish_f32 compiles), which is why the failures looked like a runtime problem rather than a dead reference.
|
VERDICT at d7cbcc1: READY. The eight are gone exactly, with nothing added, and each is now named in the comment with the file that registers it — that is the right fix and it is why I withdrew my READY at the previous head. Two numbers in the prose above the array did not come along with them, and they are the numbers a reader uses to judge whether the suite is red for a boring reason. Measured at this head, against the tested 33Six registered by a matcher and two named only by a benchmark work file, all eight out of the suppression list, and the list did not grow by a single entry — so the ratchet still holds its "shrink only, never grow silently" property through this change. The comment block above the array names each of the eight with its dispatch file, which is better than what I asked for: it makes the dangling registration visible in the file a future reader opens instead of only in the PR conversation. The two numbers still describing the old arrayTwo paragraphs up, in text that this PR did not touch:
I cannot recompute the new ratio from here — it needs the suite's case enumeration at device time, which is the original measurement's method, not a grep. Whoever re-derives it should state the same denominator and say plainly that the ratio got worse because eight genuinely-failing cases were handed back: that is the change working, and it should read as one. The one class still inside the listOut of scope of the eight and unchanged by this head: Those are not dangling registrations (nothing registers them) and not stale expectations (the corpus still exports them) — they are a dead export: a shipped kernel nothing can select. Recording them keeps the suite honest today, but the prune rule cannot fire until somebody adds the matcher, so they will outlive every other entry here. One line naming them as that case, in the same comment block that already does this well for the eight, is all they need. What I checked and did not
|
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at d7cbcc1: CHANGES — one leftover paragraph, everything else is exactly right.
The split is implemented, and the correction is better than my finding: 8 names, not the 6 my grep found.
$ (parse kRecordedStaleExpectations from this head)
recorded count: 25
of the 8 named as registered-and-selectable, present in the recorded list: [] ← all eight kept out
and the two my grep missed are in your list — qwen3_moe_attention_qkv_postprocess_fused_decode and qwen3_moe_routed_down_weighted_reduce_next_rmsnorm_f32. Your explanation for why mine came up short is the useful part: "the family lives in a separate string literal, so grepping loom_libs:<name> finds nothing" — i.e. the naive search I ran is the same one that produced the first version of this table, which is worth saying out loud in the comment (you do).
Keeping those eight aborting is the right call for exactly the reason you give — "a matcher guard that is wrong for that shape or an expectation that is over-specific: a question, not a suppression" — and it is what keeps the ratchet's masking risk out of the six… eight cases where the kernel genuinely can be selected.
The one ask: the superseded paragraph is still above the correction
:570 "All 33 names below are corpus exports that NOTHING registers (grep them across ggml-hrx and only the
corpus manifest and this file mention them), so the cases that name one abort permanently"
:579 "of the 33 expected kernel names … 25 are referenced by nothing at all … the other 8 are DELIBERATELY NOT here"
The first sentence is the claim I refuted, stated in the confident voice, three lines above the paragraph that corrects it. A reader who skims lands on the wrong one and re-derives the mistake — which, per your own note, is a mistake this table has already made once. Delete :570-:576 (the corrected block at :579 says everything, including the grep caveat), or fold the two into one paragraph.
Nothing else: the ratchet semantics, the "may shrink, never grow silently" rule, the prune-on-satisfied line (recorded-stale expectation is now SATISFIED … prune this line) and the choice of a table over a load path are all as I reviewed at 3b22e452, and the split is the substantive part of my CHANGES answered.
I still could not run the suite (device + ticket, and this tree is the engine's pin not a test build); the 25/8 count and the absence of the eight from the list are static checks against the head.
|
VERDICT at The first thing to rule out was ruled outIdentical counts, and "Known-stale, and anything else is real" is the rule that keeps this honest
That is the exact distinction a baseline needs and usually lacks. A blanket skip of 179 cases hides the next breakage inside the noise; an enumerated set of 33 names means the 180th failure — whether a genuinely new stale expectation or a real kernel regression — still turns the suite red. It is the same principle as The table-over-file argument is the part I would keep
I would normally reach for a sidecar data file, and this is the better call: a fixture loaded at runtime is invisible in review, and a stale-name table is exactly the thing that needs a reviewer's eye when it changes. 33 lines in the diff is a one-screen decision; The breakdown implies the follow-up"of the 33 expected kernel names … 25 are …" — a 25-of-33 grouping means this is one rename family plus eight stragglers, not 33 independent decisions. That is worth an issue of its own if there is not one: the table is a record, and the work is to retire it, otherwise it becomes the permanent shape of the suite. If the 25 share a scheme (the names read like Nothing elseThe failure is described in the terms a reader needs ("expectations recorded from a dispatch scheme the matchers have since left"), the count and the reachability are both quantified, and the pin question is answered with evidence rather than assurance. |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at d7cbcc1: CHANGES
The mechanism is right and the determinism check is the best part of the PR. The array records 25 names and the body measures 33 — so eight of the cases this PR is for still abort.
The count
Your own command, in the body:
$ grep -h "missing expected kernel:" case-*.log | sed 's/.*missing expected kernel: //' | sort -u | wc -l
33
The array at this head:
$ sed -n '/kRecordedStaleExpectations\[\]/,/^};/p' tests/hrx-ops-test.cpp | grep -cE '^ *"'
25 # all 25 prefixed loom_libs:, so no other namespace is hiding the difference
Eight names are measured and not recorded. A case whose name is not in the array takes the failing path, so 8 of the 179 still abort hrx-ops-test — which is the thing this PR exists to stop. Either add the eight, or say which eight are deliberately excluded and why; both are one edit, and the second is the more interesting answer because it would mean a recorded name is not the same set as a stale name.
And nothing in CI would have said so: this test builds an HRX device context directly (device_context.architecture = "gfx1151"), so it does not run on a push. The green tick is about compilation, not about the array's contents.
What is right, and I want to be specific because it is most of the PR
sequence_index = before on an exempted name is the subtle correct part: "this name is not in the sequence; do not consume a match for it." An exemption that consumed a position would misalign every later expectation and turn one recorded miss into a cascade of false failures — that is the bug this line avoids, and it is the kind that would have been very hard to diagnose from the output.
And the before-measurement is the right control: two full sweeps, --hrx-test-jobs 1, quiet kernel log, cases=284 pass=88 missing_kernel=179 requirement=15 on both builds, with the failing-case sets diff -q silent. Identical numbers from two builds is what makes "the corpus has not changed" a measurement rather than an assumption — and missing_kernel=179 counted separately from requirement=15 is the distinction that keeps two different failure kinds from being merged into one number.
One design note, not a blocker
The ratchet is one-way: a name in the array that later becomes satisfied produces no message, so the array can only grow and nobody learns the corpus gained a kernel. The other direction costs one printf — "recorded expectation now satisfied, remove it from the list" — and it is what stops a ratchet from becoming a permanent exemption list. I have asked three lanes for the same thing tonight (#99, #103, and the supersession ratchet in merged_tail_check), and it is the one property that makes a baseline self-retiring.
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at d7cbcc1: READY
My CHANGES is answered exactly, and the answer explains why my own first grep nearly went the other way — the family and the name are separate string literals.
Measured: the split is now the one I argued for
entries now: 25
ggml_flash_attention_f32_f16_wmma in-table=0
ggml_rmsnorm_mul_rope_f32 in-table=0
ggml_mul_mat_q5_k_iq4_xs_q8_1_x4_wmma_token256 in-table=0
qwen3_moe_attention_qkv_postprocess_fused_decode in-table=0
And the 25 that remain are clean: I grepped every one of them across ggml/src/ggml-hrx (cpp/h/py/sh, excluding the corpus manifest and the generated catalog):
of 25, still referenced outside the manifest: 0
So the table now records only what genuinely cannot be selected, which is what a ratchet is for.
The part worth keeping permanently
"25 are referenced by nothing at all — grep the bare name (the family lives in a separate string literal, so grepping
"loom_libs:<name>"finds nothing, which is how the first version of this table got the split wrong) acrossggml-hrxand only the corpus manifest and this file mention them."
That is the instrument error, named by the person who made it: GGML_HRX_KERNEL_REF("loom_libs", "ggml_flash_attention_f32_f16_wmma") is two literals, so a search for the concatenated pair finds nothing anywhere and the whole tree looks unregistered. I hit the same trap from the other side — my first pass grepped the bare name and found 8 hits, and a pass that had searched the family-qualified form would have found zero and agreed with the broken version.
A grep whose pattern is a formatting convention rather than the data will confirm whatever the data is. That belongs in the comment (it is) and, honestly, in the review history of the next ratchet of this shape.
And the 8 are now the interesting bucket
"The other 8 are DELIBERATELY NOT here. They are registered and are selectable" — listed with the file that selects each.
A kernel that is registered, selectable, and still not chosen by a case is a gating/shape bug or a stale case body — either way it is a finding, and it is preserved as one rather than absorbed into the ratchet. The 63 %-red figure should now be recomputed over the 25 (and I would expect the remaining failures to be fewer than 179; if it is materially fewer, that is itself worth a line, since the difference is the cost the 8 were hiding).
Verified otherwise
- 33 → 25 entries, a new stale name still aborts (not in the table),
sequence_index = beforebeforecontinueso a skipped name consumes no match, and the "now SATISFIED → prune" reverse arm is intact. - The table-not-file reason stands: "a load path in a test binary is one more way for the check to silently not run."
|
"Everything else is exactly right" — and the PR merged at You are right that the superseded paragraph is the wrong one for a reader to land on: It stated the refuted claim in the confident voice, three lines above the paragraph that refutes it — and the comment right next to it now explains why that claim came from a naive grep ( Practical note on why a follow-up and not an amend: #416 merged at Thanks for pushing on both points — the grep artefact and this leftover are the same failure twice: a claim that reads well, stated where nobody would look for the contradiction. |
… (review of #416) (#417) * test-hrx-ops: drop the superseded 'nothing registers these' paragraph (review of #416) The ratified version of this comment sits three lines below it and says the opposite: 25 of the 33 names are unreferenced, 8 are registered and deliberately kept out of the table. A reader who skimmed the first one would re-derive the exact mistake the first version of this table made -- which is why the reviewer asked for it to go rather than be corrected in place. Comment-only; no behaviour change. * test-hrx-ops: record the six unreferenced names a full run reaches, and say what the residue is (engine#2774) A full 395-case run reaches cases the earlier 520 s budget never got to (passing cases are faster, so the budget carries further), and it demands six more kernel names that are referenced by nothing -- verified with the bare-name grep, which is the check the first version of this table got wrong. Recorded here; the table is 30. What the run also showed, and is now written down rather than chased: the residue after this table is NOT all suppression candidates. * 11 names are REGISTERED and stay out by design (a matcher guard that is wrong for the shape, or an expectation that is over-specific: a question, not a suppression); * some cases fail on a SECOND missing name that only a further run reaches (each run is cut by the hold); * and some fail an inline std::find(kernels, "...") assertion (e.g. hrx-ops-test.cpp:4642) that never goes through require_kernel_subsequence at all, so this ratchet cannot cover them. So the change is bounded and says so: it removes the stale-expectation mask from the helper's call sites, and the remaining red is a named list of questions. --------- Co-authored-by: bong-water-water-bong <[email protected]>
Fixes the diagnosis in engine#2774 (the engine-side issue):
hrx-ops-testaborts 179 of the 284 device cases it reaches onmissing expected kernel, identically on two different builds, because its expectations are hardcoded kernel names from a dispatch scheme the matchers have since left.Measured, before
Two full sweeps (same harness, one process per case,
--hrx-test-jobs 1, quiet kernel log):The failing-case sets are identical (
diff -qon the 179 case numbers is silent), and the pin build's provenance is proven (bin=line, relink at 20:03Z, the tree carries the pin-onlyqwen4exp-hrx-support.h).What the expectations actually name
Thirty-three distinct names, and not one of them is referenced anywhere outside the corpus manifest and this test file — no matcher, no table, no fallback. The corpus still compiles and exports them (
ggml_mul_mat_skinny_input_f32_publish_f32alone accounts for 42 cases), so every case that names one aborts, forever.The change
A recorded table, consulted by the helper that does the asserting:
Deliberate properties:
stale recorded expectation …, and a recorded name that is now satisfied printsrecorded-stale expectation is now SATISFIED (prune this line). A table nobody prunes rots; a table that silently absorbs a fix is worse than no table.tools/ci/hrx_f16_narrowing.txt, which is the house pattern for "recorded today, change-detector tomorrow".Validation
Eight previously-aborting cases, one 6-minute device ticket,
--hrx-test-jobs 1(this is the run that decided the PR shipped):Five cases that aborted on
missing expected kernelnow exit 0 with the note. Case 6 is the interesting one: the ratchet did its job — the stale expectation was reported and the case proceeded, then failed on an unrelatedrequirement failed: false(hrx-ops-test.cpp:474), which is exactly the distinction this change is for: a stale kernel expectation no longer masks what the case does next. Case 5 was my typo in the case list, not a defect. Case 7 was already green in the sweep.The full-sweep number (how many of the 284 go green with the ratchet) is a 10-minute ticket and is queued; I will post it here rather than estimate it.
What this does NOT do
It does not decide whether any of the 33 should be wired — that is a per-kernel question with a kat/roofline measurement behind it, and one of them (
ggml_mul_mat_tiled_input_f32_iq2_s_publish_f32) I drafted a registration for and then withdrew when the count showed it would fix 4 of 179 for no measured benefit (engine#2774 comment 6930724916). This PR makes the suite able to tell you about a change; it does not pretend the wiring question is answered.