Repository navigation
tests: per-case runner and the #445 ACCEPT rows - #105
Merged
bong-water-water-bong merged 2 commits intoOct 18, 2026
Merged
Conversation
The suite is one fail-fast main(), so one red case hides every case after it - and engine #445 keeps 9 REGRESSION rows red on purpose. Replace main() with a table of cases and a runner that reports [PASS]/[FAIL] per case plus totals and exits non-zero if any case failed. REQUIRE throws a RequirementFailure that the runner catches instead of calling std::abort(); each case keeps its own expectations, so a red row is a row and not the end of the run. Then take the #445 ACCEPT rows this tree still had stale (#104 had already made some): - gather_add_dispatch: the (2048, 13, 1, false) manual graph, the 96-hidden variant and the partial graph are claimed through the generic path now (get_rows x2 + binary_strided, three dispatches) where they were refused; the canonical shape still fuses to hrx:ggml_gather_add_f32, and the strided-coalesced variant is still refused. - swiglu_q8_output: the q8-output publish kernel went with f2099e9; the shape is the kquant swiglu decode feeding the kquant matmul decode, which reads f32, so there is no producer or alternate to bind. - qwen_flash_attention_dispatch: a QK-layout (MLA) shape routes to ggml_attention_rows_f32_f16 (strided extents, bindings 5, no gate) rather than the flash kernel; the gated transposed F16 variant is claimed now, the F32-value one is still refused. Not re-added: generic_swiglu_k16_publication_edges, whose case #104 dropped. Left as they are: the REGRESSION rows and qwen_router_top8_dispatch (NEEDS-DEVICE). Host suite here: 47 passed, 13 failed, 60 total; device cases skipped (no HRX device). Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ine #445) Owner approved turning the accepted regressions into guards that cannot be quietly accepted. Adds a KNOWN-FAIL status to the case runner and restores the cases the ruling was about. Runner: a case can carry known_fail("#449") or known_fail("#450"). It must fail while the regression stands: the runner prints [KNOWN-FAIL #449]/[KNOWN-FAIL #450] and counts those apart from the suite's own failures, so the exit code is driven only by real FAILs (and by an UNEXPECTED-PASS, which prints [UNEXPECTED-PASS #nnn] and exits non-zero: someone fixed or changed it, so the marker has to be retired on purpose). Restored with their original pre-#104 expectations (the plan each regression net was built to protect), adapted only to compile against the current API - activation_publication_diagnostics() is alternate_values() now, and common_symmetric_i4_lowrow_mul_mat_eligible() lived in the header f2099e9 deleted: #449 (publication dropped whole in f2099e9) generic_swiglu_k16_publish, tiled_matmul_alternate_publish, rmsnorm_binary_f16_output, qwen_decode_publication_consumer_qualification, qwen_weighted_reduce_next_rmsnorm_q8_publication - re-added, #104 had deleted them packed_f16_producer_consumer, rmsnorm_binary_k16_output, gdn_rmsnorm_gate_dispatch - the three #104 had rewritten to pass, put back to their original expectations #450 (symmetric-i4 consumer route re-enabled in aadd602) symmetric_i4_consumer_qualification - re-added, #104 had deleted it Host suite here: 66 case(s): 44 passed, 13 failed, 9 known-fail, 0 unexpected-pass. The 13 failures are the same rows #105 reports (class A plan-shape, class B kernel-name, and the NEEDS-DEVICE qwen_router_top8_dispatch), so the accepted regressions are visible without being failures. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This was referenced Oct 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Engine #445's ruling (table accepted) carried onto the suite that #104 rewrote. Two parts:
The runner.
main()was one fail-fast sequence ofrun_*()calls, so the first red case hid every caseafter it - and hrx: the fused F16 routed-FFN decodes the table with the layout it was written with (engine#2861) #445 keeps 9 REGRESSION rows red on purpose, so the suite could never report past them.
main()is now a table of cases plus a runner that prints
[PASS]/[FAIL]per case and totals, and exits non-zero ifany case failed.
REQUIREthrows aRequirementFailurethat the runner catches instead ofstd::abort(); everycase keeps its own expectations, and a case still stops at its own first failure.
The ACCEPT rows this tree still had stale, each citing its hrx: the fused F16 routed-FFN decodes the table with the layout it was written with (engine#2861) #445 row in the code:
gather_add_dispatch-(2048, 13, 1, false), the 96-hidden variant and the partial graph are claimedthrough the generic path now (
ggml_get_rows_f32x2 +ggml_binary_strided_f32, 3 dispatches) where theywere refused; the canonical shape still fuses to
hrx:ggml_gather_add_f32and the strided-coalesced variantis still refused.
swiglu_q8_output- the q8-output publish kernel went with f2099e9; the shape is the kquant swiglu decodefeeding the kquant matmul decode, which reads f32, so there is no producer or alternate to bind.
qwen_flash_attention_dispatch- a QK-layout (MLA) shape routes toggml_attention_rows_f32_f16(stridedextents, 5 bindings, no gate) instead of the flash kernel; the gated transposed F16 variant is claimed now,
the F32-value one is still refused.
rmsnorm_gate_packed_output,rmsnorm_gate_q8_output,qwen_token_embedding_dispatchandgdn_native_projection_pair_dispatchwere already made by tests: build the HRX tests against the ggml-hrx we ship (engine#422) #104;iq2_codebook_resource_reuseno longer exists(its codebook path is gone from the backend);
generic_swiglu_k16_publication_edgeswas dropped by tests: build the HRX tests against the ggml-hrx we ship (engine#422) #104 and isnot re-added.
Gate: this table (the fork has no CI)
1bit-MONSTER/llama.cppruns no checks on this branch, so the local host run below is the gate, not a CI result.CPU only (ryzen), no HRX device present, so the device cases skip:
statuscommand_plan_metadatadispatch_registrygraph_importgraph_import_mixed_backend_boundarygraph_view_external_usescale_f32_dispatchcont_f32_dispatchbinary_f32_broadcast_dispatchgraph_snapshot_diagnosticsunmatched_graph_diagnosticscompletion_counter_plangraph_indexrope_set_rows_dispatchgraph_traversalqwen_token_embedding_dispatchgather_add_dispatchqwen_flash_attention_dispatchqwen_attention_postprocess_dispatchqwen_matmul_dispatchpacked_f16_producer_consumerk16_major_preparation_reusermsnorm_binary_k16_outputswiglu_q8_outputrmsnorm_gate_packed_outputrmsnorm_gate_q8_outputlowtoken_residual_dispatchquantized_conv4_dispatchgdn_rmsnorm_gate_dispatchgdn_native_projection_pair_dispatchgdn_selected_snapshot_dispatchgdn_selected_rms_q8_dispatchllama_attention_matmul_dispatchquantized_value_projection_dispatchschedule_qwen_terminal_q6k_q8_command.tokens1schedule_qwen_terminal_q6k_q8_command.tokens18schedule_get_rows_q8_1_alternate_command.q4_kschedule_get_rows_q8_1_alternate_command.bf16qwen_router_top8_dispatchcommon_mul_mat_id_swiglu_dispatchqwen_routed_gate_up_dispatchcommon_mul_mat_id_postops_dispatchalias_value_importmulti_dispatchlayout_alias_scheduler_elisionzero_output_scheduler_elisiontransient_importgraph_view_preserves_shared_output_storagechained_dispatch_requires_transientsgraph_replay_host_staging_is_not_ineligiblemultiple_transient_plandisjoint_transient_plan_packingcommand_program_kernel_dumpcommand_shape_hashgraph_program_cache_uid_mismatchgraph_match_hash_collisiongraph_match_bijectionvalidated_graph_uid_matchgraph_executor_contractloom_async_jit_environmentThe 13 red rows are the #445 rows outside the accepted set: class A plan-shape rows
(
qwen_attention_postprocess,qwen_matmul,lowtoken_residual,disjoint_transient_plan_packing,gdn_selected_rms_q8), class B kernel-name rows (quantized_value_projection,qwen_terminal_q6k_q8.tokens1,get_rows_q8_1_alternatex2,common_mul_mat_id_swiglu,qwen_routed_gate_up,common_mul_mat_id_postops) andthe NEEDS-DEVICE row
qwen_router_top8_dispatch, which stays red as ruled.One thing the owner should see
The 9 REGRESSION rows from #445 do not protect anything on this branch any more: six of the cases no longer exist in
#104's suite (
generic_swiglu_k16_publish,tiled_matmul_alternate_publish,rmsnorm_binary_f16_output,qwen_decode_publication_consumer_qualification,qwen_weighted_reduce_next_rmsnorm_q8_publication,symmetric_i4_consumer_qualification), and the three that remain (packed_f16_producer_consumer,rmsnorm_binary_k16_output,gdn_rmsnorm_gate_dispatch) pass, i.e. their expectations were rewritten to the currentplans. That is the opposite of the ruling's "keep them red", and it means #449 and #450 have no test in the way of
their regressions being accepted by default. I left them exactly as #104 left them, as this task said.
Related: engine #445 (ruling), #449 (publication dropped in f2099e9), #450 (symmetric-i4 route re-enabled).
🤖 Generated with Claude Code
Owner approved the known-regression follow-up. Added to this PR (#105 is still open, so no stacked
PR): the accepted regressions become guards that cannot be quietly accepted.
1. KNOWN-FAIL in the runner
A case can carry
known_fail("#449")orknown_fail("#450"). It must fail while the regression stands: therunner prints
[KNOWN-FAIL #449]/[KNOWN-FAIL #450]and counts those apart from the suite's own failures, sothe exit code is driven only by real
[FAIL]rows. If a known-fail case passes, the runner prints[UNEXPECTED-PASS #nnn]and exits non-zero - someone fixed or changed it, so the marker has to be retired onpurpose instead of silently rotting.
2. The six cases #104 deleted, back with their original expectations
Restored verbatim from the pre-#104 file (the plan each regression net was built to protect), adapted only where
the API no longer has the member:
activation_publication_diagnostics()isalternate_values()now(
graph_value/type), andcommon_symmetric_i4_lowrow_mul_mat_eligible()lived indispatch-registration/common/dispatch-symmetric-i4.h, which f2099e9 deleted with the route switch it guarded.generic_swiglu_k16_publish,tiled_matmul_alternate_publish,rmsnorm_binary_f16_output,qwen_decode_publication_consumer_qualification,qwen_weighted_reduce_next_rmsnorm_q8_publication.aadd6025after ourf2099e9bremoved it):symmetric_i4_consumer_qualification.3. The three #104 had rewritten to pass, back to their original expectations, tagged #449
packed_f16_producer_consumer,rmsnorm_binary_k16_output,gdn_rmsnorm_gate_dispatch.Gate: this table (the fork has no CI)
1bit-MONSTER/llama.cppruns no checks on this branch. CPU only (ryzen), no HRX device, so the device casesskip. Command:
cmake --build build --target hrx-backend-test && ./build/bin/hrx-backend-test.statuscommand_plan_metadatadispatch_registrygraph_importgraph_import_mixed_backend_boundarygraph_view_external_usescale_f32_dispatchcont_f32_dispatchbinary_f32_broadcast_dispatchgraph_snapshot_diagnosticsunmatched_graph_diagnosticscompletion_counter_plangraph_indexrope_set_rows_dispatchgraph_traversalqwen_token_embedding_dispatchgather_add_dispatchqwen_flash_attention_dispatchqwen_attention_postprocess_dispatchqwen_matmul_dispatchpacked_f16_producer_consumerk16_major_preparation_reusermsnorm_binary_k16_outputswiglu_q8_outputrmsnorm_gate_packed_outputrmsnorm_gate_q8_outputlowtoken_residual_dispatchquantized_conv4_dispatchgdn_rmsnorm_gate_dispatchgdn_native_projection_pair_dispatchgdn_selected_snapshot_dispatchgdn_selected_rms_q8_dispatchllama_attention_matmul_dispatchquantized_value_projection_dispatchschedule_qwen_terminal_q6k_q8_command.tokens1schedule_qwen_terminal_q6k_q8_command.tokens18schedule_get_rows_q8_1_alternate_command.q4_kschedule_get_rows_q8_1_alternate_command.bf16qwen_router_top8_dispatchcommon_mul_mat_id_swiglu_dispatchqwen_routed_gate_up_dispatchcommon_mul_mat_id_postops_dispatchalias_value_importmulti_dispatchlayout_alias_scheduler_elisionzero_output_scheduler_elisiontransient_importgraph_view_preserves_shared_output_storagechained_dispatch_requires_transientsgraph_replay_host_staging_is_not_ineligiblemultiple_transient_plandisjoint_transient_plan_packingcommand_program_kernel_dumpcommand_shape_hashgraph_program_cache_uid_mismatchgraph_match_hash_collisiongraph_match_bijectionvalidated_graph_uid_matchgraph_executor_contractloom_async_jit_environmentgeneric_swiglu_k16_publishtiled_matmul_alternate_publishrmsnorm_binary_f16_outputqwen_decode_publication_consumer_qualificationqwen_weighted_reduce_next_rmsnorm_q8_publicationsymmetric_i4_consumer_qualificationAll nine tagged rows report
KNOWN-FAIL, noneUNEXPECTED-PASS, and the 13 realFAILrows are exactly the ones#105 reports (class A plan-shape, class B kernel-name, and
qwen_router_top8_dispatchNEEDS-DEVICE) - so the restof the table is unchanged and the accepted regressions are visible without being failures.
Deferred device work (recorded in
~/NEED-GPU-T422.md): the 14 device cases, theqwen_router_top8measurement,the symmetric-i4 on/off measurement, and the MLA (QK-layout) flash_attention shape that now routes to
ggml_attention_rows_f32_f16: same model/prompt/-ub, measure kernel time or tok/s for the rows route vs theflash kernel and logits/argmax equality, after the #315 cell.
Related: engine #445 (ruling), #449 (publication), #450 (symmetric-i4 route).
🤖 Generated with Claude Code
#450 marker retired (commit
63644da5)Engine #450 was re-measured on hardware and the accepted regression is not one. Qwen3-4B-Q5_K_M on gfx1151, route on vs off (
GGML_HRX_DISABLE_DISPATCH=common.rmsnorm_binary_symmetric_i4_k32),-dev HRX0 -ngl 99 -t 4:Held-out Gutenberg text (Pride and Prejudice + Moby Dick): PPL 16.3451 ± 0.74733 over 20 chunks, cross-arm KLD over 5 chunks 0.000000 ± 0.000000 (max 0.000056, max Δp 0.005 %), and three 64-token greedy completions byte-identical (931 bytes each).
f2099e9b's "substantial numerical performance regression" is not observable on AMD's current kernels.So
symmetric_i4_consumer_qualificationnow states what ships: its qualifying graphs (Q5_K/IQ4_XS weight consuming the normalised value, directly or through a reshape) selectloom_libs:ggml_rmsnorm_binary_symmetric_i4_k32, and a graph with no such consumer does not. Its old q8-publication assertions are #449's territory and stay with the guards there.Host suite now: 66 cases - 45 passed, 13 failed, 8 known-fail, 0 unexpected-pass (was 44/13/9). #450 closes when this merges.