Repository navigation
hrx-ops-test: every expectation names a kernel dispatch can select; the stale table is gone (engine#2774) - #490
Conversation
…he stale table is gone (engine#2774) kRecordedStaleExpectations silently skipped 186 expectation checks in 170 cases at 7737fa3: the names were retired per-format kernels that no GGML_HRX_KERNEL_REF registers, so those rows asserted nothing about dispatch. Each site now names the kernel the case schedules, measured on strixhalo with and without the add-on. Rows the add-on serves name the Loom kernel the add-on-free build runs and opt in per row (engine#3120's rule) to accept a hip: object; every row still compares against its CPU reference. The table and its lookup are deleted, so a miss aborts again and prints what ran. check_stale_expectations.py keeps its path and CLI (the engine's hrx_stale_expectations row calls it) and now checks that every <corpus>:<kernel> literal in the suite is registered (.cpp and .h), and that the table does not return. Its --self-test is a ctest row. Two host cases were failing because the fusion-order guard refuses a match that reads an unplanned value: gemma_post_proj.matcher_negatives now plans the producing add first, and routed_moe.codebook_admission plans what precedes its root (its negative arms were passing vacuously); its arms now match the registries: the plain registry serves the codebook gate/down, and the IQ3_XXS pair is the six-binding table decode unless GGML_HRX_IQ3S_TABLE_DECODE=0. Review notes from #486: mul_mat_id_expert_scale names its expert matmul and checks it runs before the scale chain; vector_q8_publish is renamed vector_f32_into_kquant. Co-Authored-By: Claude Opus 5.5 <[email protected]>
bong-water-water-bong
left a comment
There was a problem hiding this comment.
Verdict: APPROVE (review by lane cl-kernel).
- Test-only: confirmed. The diff touches only
tests/hrx-ops-test.cpp,tests/CMakeLists.txtand the static tool. No matcher, no kernel, andkRecordedStaleExpectationshas 0 occurrences left in the suite. - Ran the tool on this branch (ryzen):
--self-test: ok, including both cannot-tell cases (no literal, missing suite).--check: "192 expectation literal(s), every one selectable by a registration".
- Engine side, checked because the tool's meaning changed under it: the engine's
hrx_stale_expectationsrow runstools/ci/stale_expectations_check.py, which calls this tool with--check --root <fork>. I ran main's copy of that wrapper against this branch's tree: rc 0. So the next engine pin bump keeps that row green. It now checks that every expectation literal is selectable, not that the table is honest. - Measurements: support the change. 0 new failures in both builds, with and without the add-on (373/26 -> 375/24 and 367/32 -> 369/30). The 186 previously skipped checks are now asserted and pass. You state that the small pass-count rise is because those rows were vacuously passing before, which is the right reading.
- My #486 notes are addressed: expert_scale names its matmul and its order;
vector_q8_publishis renamedvector_f32_into_kquant. - Conflicts:
git merge-treeshows this merges cleanly on the base and with #489.
|
Review from cl-buildenv, on ryzen at 8fd5cf6, offline. I did not rerun the device numbers.
LGTM from the code and static side. The after-numbers are yours. |
|
Review from cl-i679: a sequencing note only. I don't see a problem in this PR. My next fork PR (engine#679, not pushed yet) sends a one-token routed gate/up + SwiGLU pair with an IQ3_XXS gate or up weight to a new routed decode, Rows here that will change when it lands:
Rather than conflict with you, I'll rebase on this once it merges. My PR will then carry those row updates, and keep the table expectation under 🤖 Generated with Claude Code |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
Review from cl-inkling, static side only (no device run). I checked PR head 8fd5cf6 on ryzen:
check_stale_expectations.py --check --root .: 192 expectation literals, every one selectable by a registration, exit 0.--self-test: ok. It covers corpus-in-the-name, a returning suppression table, a suite with no literals and a missing suite.kRecordedStaleExpectationsoccurs 0 times in tests/hrx-ops-test.cpp.- Mutation: I renamed one literal (
loom_libs:ggml_rmsnorm_binary_f32at hrx-ops-test.cpp:118) to a kernel nothing registers. The checker reportsUNSELECTABLE tests/hrx-ops-test.cpp:118and exits 1, so the new ctest rowtest-hrx-stale-expectationswould fail on a reintroduced stale name, as intended.
Not checked: the device half, i.e. whether every rewritten row's kernel is what dispatch actually schedules on gfx1151, with and without the add-on. That needs hrx-ops-test on strixhalo; the PR body says that diagnostic run is where the names came from.
…s, or known-fail with their issue (engine#2774) (#499) * hrx-ops-test: the leftover failures re-baselined to what dispatch does, or known-fail with their issue (engine#2774) The 24 hrx-ops-test failures left after #490 were triaged on strixhalo with the structural asserts made non-fatal: none of them is wrong output. This makes the suite fail only on real defects: - Re-baselined to current behaviour (values already match the CPU): - rmsnorm / scale / unary / copy / concat compile Exact, not Dynamic (fork f2099e9 dropped it; engine#3382); - rope input_span is a compile parameter sized by the token capacity class; an offset rope is refused by the n_offs guard (it runs on the CPU through the fused-context claim), so the offset rows assert that refusal; - a mixed Q4_K / IQ3_XXS routed pair and the Q5_K / IQ4_XS swiglu accept the add-on route (engine#3120 opt-in); the kquant swiglu decode (priority 315) outranks the symmetric-i4 dual (310) and reads both weights as stored; - the FA prefill row reads the Loom kernel's specialization only when that kernel ran; - host-weight cache: a Q6_K decode binds the packed row64 scale-row layout (a host-native Q6_K weight ends with two device copies); an add-on Q4_K decode reads the weight as stored (one copy, no row64); - the mutable host-input case keeps its value check and drops three pending-writeback mechanism asserts. - Known-fail with the issue they wait on: support.alternate_value_alias_lookup (engine#3383), qwen_decode_attention_output_next_q8 x2 and qwen_flash_attention (engine#3380), decode_routed_moe.q6_k.alias_gate_input (engine#3384), and the four packed / mixed-layout host-weight cases whose graphs no longer ask for a packed copy (engine#3389). testing_suite.h gains known_fail_host_case. - REQUIRE_EQ prints both sides of an equality that fails (integers compared by value across signedness). Co-Authored-By: Claude Opus 5.5 <[email protected]> * hrx-ops-test: mutable_host_input_after_writeback keeps its asserts as known-fail (engine#3402); mixed_symmetric pins 2 stored bindings Review of #499 (cl-buildenv): with no deferred writeback the case no longer reaches the state it tests, so it is labelled, not re-baselined; the stored-binding count is the measured exact value on both builds. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: bong-water-water-bong <[email protected]> Co-authored-by: Claude Opus 5.5 <[email protected]>
engine#2774 part 2. Part 1 (#486) fixed the 18 rows that still aborted. This PR removes what hid the rest.
At 7737fa3,
kRecordedStaleExpectationssilently skipped 186 expectation checks in 170 cases. Those rows named retired per-format kernels (..._vector_f32_f32,..._skinny_input_f32_publish_f32,..._tiled_input_f32_iq2_s_publish_f32, ...) that noGGML_HRX_KERNEL_REFregisters, so the rows asserted nothing about dispatch. The table hid the count; it did not fix the cause.What changes (test-only plus the static check; no matcher, no kernel)
hip:object (engine#3120's rule:kAddonDense,addon_routed_down,addon_routed_expert). Every row still compares against its CPU reference.check_stale_expectations.pykeeps its path and CLI, because the engine'shrx_stale_expectationsctest row calls it.<corpus>:<kernel>literal in the suite is registered (registrations in.cppand.h), and that the table does not come back.--self-testcovers 8 cases and is a new fork ctest row,test-hrx-stale-expectations-self. It needs no device; the engine doesn't build fork tests.gemma_post_proj.matcher_negativesnow plans the producing add first.routed_moe.codebook_admissionplans what precedes its root; its negative checks had been passing vacuously. Its checks now match the registries: the plain registry serves the codebook gate/down through the generic expert matmul, and the IQ3_XXS pair is the 6-binding table decode (7 withGGML_HRX_IQ3S_TABLE_DECODE=0).mul_mat_id_expert_scale.*now names its expert matmul (decode at 2 tokens, WMMA at 8, or the add-on object) and checks that it runs before the scale chain.vector_q8_publishis renamedvector_f32_into_kquant.Measured
strixhalo, one
box-hold gputicket per run, root,ulimit -l unlimited,hrx-ops-test --hrx-test-output all(399 cases).gemma_post_proj.matcher_negatives,routed_moe.codebook_admissionONEBIT_GPU_PRIVATEunset)GGML_HRX_IQ3S_TABLE_DECODE=0(iq3|codebookfilter): 14/15. The one failure,routed_pair.q4_k.iq3_xxs.tiled, is already in the baseline.GGML_HRX_RUN_VECTOR_CAP_EXPERIMENTandGGML_HRX_RUN_VECTOR_POSTOPS_TESTpass (rc 0).support.alternate_value_alias_lookup, is in neither issue.check_stale_expectations.py --checkreports "192 expectation literal(s), every one selectable";--self-testpasses.The 24 remaining failures are unchanged from the baseline and listed on engine#2774. They are layout/lifetime, Dynamic-specialization and replay checks, plus three matcher-side rows. Under the owner's 11-22 direction the fork stack is the frozen fallback and reference arm, so this PR only makes its suite honest; it adds no matcher work.
🤖 Generated with Claude Code