Skip to content

CC engine: per-half probe between tiebreak and MRV + reversed-BFS row order (-cc-roworder=auto, GH-206; do not merge before PI says merge) - #215

Merged
guluchen merged 8 commits into
mainfrom
experiment/gh-206-cc-roworder-auto
Oct 30, 2026
Merged

guluchen merged 8 commits into
mainfrom
experiment/gh-206-cc-roworder-auto

Conversation

@guluchen

Copy link
Copy Markdown
Owner

Experiment record for #206 (hub #15). Stacked on PR #204 (#183), which is stacked on PR #180 (#162). Do not merge before the PI says merge.

What changed

New value -cc-roworder=auto (opt-in; the default stays index). Each searched CSS half holds two exact level searches:

A searches from level 1. At the first level that A refutes in at least -cc-probe=S seconds (default 0.1 s):

  • B re-runs the same level, aborted through the existing poll hook once it has used A's search time (finder slices excluded);
  • if B ends EMPTY first, B searches the rest of that half, otherwise A does;
  • there is one probe per half, and no probe once the half is finished (lb >= U).

-cc-probe-growth=F (F >= 1) adds re-probes at F times the last probe level's time. It is off by default: in Tier 5 no re-probe ever changed a decision, and each cost one level.

Soundness (MODIFICATIONS.md, GH-206):

  • A and B are each exact level searches.
  • The precondition of every later level is established by the earlier refutations, whichever exact search produced them.
  • A probe changes no bound: the probe level is already refuted, and an aborted probe is discarded.
  • A probe that returns FOUND or INCONSISTENT after an EMPTY is a trap.
  • Timing noise can change speed, never answers.

Test-only mutant 21: after every refuted level, the probe runs level w + 1 with a zero time cap, and an aborted probe is counted as a refuted level.

Development note

The first version (one probe at the first level >= 1 s, binary ab91aac) failed Tier 3: TN_144 was 1.33x tb, because the probe ran on the last refuted level. It also missed most Tier 2-3 gains, because those runs finish before a level reaches 1 s. Its records are in optimization/experiments/GH-206/v1_ab91aac/. The current version fixes both problems:

  • probes start at 0.1 s;
  • there is no probe once the half is finished;
  • the default is one probe per half (14ec146 introduced the first two; fca5d3c sets the single-probe default).

Tier 0 (14ec146): PASS

  • make test-cc: CC_ENGINE_TESTS PASS. Part B: 1,800 auto driver runs against enumeration, 0 bad. They cover probes after every refuted level that always or never switch, time-based probes with threshold 0 s and poll at every node, finder on and off, and tbbase asc. Part H auto configurations: 0 bad. Mutant 21: 18/400 runs wrong. Parts R, T and the rest: unchanged and passing.
  • Identity vs [Mac agent] CC engine: MRV branching and BFS row order on top of tiebreak #183 d26070d on the tier0+1 -v logs: identical in 14 configurations. The only differences are 3 known timing-dependent MaxSAT ub-pre lines.
  • Answers: 23 tier0-3 codes x 11 auto variants, 253 runs, all correct; 151 witnesses verified by an independent GF(2) script.
  • make test-cc-flags: PASS (469 checks).

Tier 1-4 seed panel (5 seeds; cores 33-39 and 41-43)

Geomean of median wall ratios (max cell):

Tier auto vs main auto vs tb tbmrvbfs (GH-183) vs main
1 (process floor, 11 repetitions) 1.001 (1.003) 0.997 (0.999) 1.004
2 (6) 0.889 (1.216) 0.902 (1.000) 0.642 (1.216)
3 (2) 0.674 (0.978) 0.666 (0.956) 0.586
4 (1) 0.399 0.428 0.404
  • Tier 1: the single-shot panel shows LP_442 at 1.36, the usual 0.025 <-> 0.034 s process-floor flip. The repeated round-robin measurement gives every arm within ±0.5 % of main.
  • Tier 2: the max cell 1.216 is LP_544, a 0.04 s run.
  • Panel summary: auto keeps the Tier 3-4 gains (TN_144 0.46, TN_250 0.40 vs main) and part of the Tier 2 gains (BB_144 0.79, TN_108 0.67). On codes whose levels stay below 0.1 s (BB_288, GB_144, TN_200) it equals tb.

Tier 5 (6 h, default seed)

Confirmation run. Final binary fca5d3c (one probe per half), with same-session references from the same binary, on yfclab2 cores 24-35, 37-39, 41-43 (core 36 skipped: a root process uses ~16 % of it). Table: optimization/experiments/GH-206/S3_tier5_final/summary.md.

Code Same-session reference auto Probe choice
BB_756_16_30to34 tbmrvbfs lb 32 @ 11952 s lb 32 @ 12032 s (1.007) B
BB_864_4_30to40 tbmrvbfs lb 32 @ 11473 s lb 32 @ 11539 s (1.006) B
BB_1080_4_30to48 tbmrvbfs lb 32 @ 8745 s lb 32 @ 8949 s (1.023) B
TN_496_2_23to30 tbmrvbfs lb 24 @ 12224 s lb 24 @ 12308 s (1.007) B
TN_252_2_21 tb d=21 @ 11477 s d=21 @ 11376 s (0.991) A, A
TN_288_2_22to24 tb lb 22 @ 20645 s lb 22 @ 20344 s (0.985) A, A
TN_216_4_18 tb d=18 @ 661 s d=18 @ 426 s (0.644) B (X), A (Z)
TN_180_2_17 tb d=17 @ 235 s d=17 @ 176 s A, A
BB_360_12_24 (tbmrvbfs 28 s, #204) d=24 @ 34 s B
LP_1428 / 1768 / 2610 / 1122 / 1054 tb 124.0 / 15.9 / 2.98 / 4.59 / 1.69 s (clean core 34) 124.2 / 16.2 / 3.20 / 5.07 / 1.86 s A

First Tier 5 run (14ec146, re-probes at 30x; S2_tier5_growth30/). It made the same per-half decisions, and no re-probe ever switched. Each losing re-probe cost a full level, though, up to 9447 s on BB_864 at level 30. That is why the default is now one probe.

Cross-check of the #183 lower bounds (relabeled seeds 1-3, 8 h): BB_756 >= 32, BB_864 >= 32 and TN_496 >= 24 are REPRODUCED, 9/9 runs (see #183). Stems are unchanged.

Verdict

Scientific semantics changed: no (opt-in flag; default output byte-identical).
PI action required: yes (adoption decision for the stack #180 / #204 / this PR).

🤖 Generated with Claude Code

yfc and others added 6 commits October 30, 2026 05:51
…r without mrv and the bfs order with mrv

At the first level a half refutes in >= -cc-probe=S seconds (default 1) with
configuration A (index order, rules without mrv), configuration B (GH-183
reversed-BFS order, rules with mrv) re-runs the same level with an abort at A's
search time through the poll hook; the faster one searches the rest of the half.
Both are exact searches and the probe changes no bound (proof in MODIFICATIONS.md).
Tests: Part B / H driver runs with forced switch / stay / time-based probes (finder
on and off, tbbase asc); mutant 21; flag checks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e half is finished; runners, Tier 0 records of the first design

The first design (one probe at the first level >= 1 s) missed the Tier 2-3 gains
and failed Tier 3 (TN_144: the probe ran at the last refuted level). Probes now
start at 0.1 s and repeat at 30x the last probe level's time, the other
configuration being re-tried; a probe is skipped once the half needs no further
level (lb >= U). Tests and flag checks updated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… stay available

In the Tier 1-4 panel no run re-probed, and in Tier 5 no re-probe ever changed the
decision while each cost one level (LP_1768 10 s, LP_1428 14 s, TN_216 18 s). The
default is now the single probe the round was specified with.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…, LP same-session references

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ult) into GH-206

Conflicts resolved by keeping both sides:
- Driver: with -cc-roworder=auto both HalfSearch objects (A and B) get the
  GH-157 charge settings; otherwise as GH-183.
- DriverOptions: GH-157 fields and initialisers plus the GH-206 probe fields.
- cc_half.h: ROWORDER_AUTO enum plus the GH-157 LbWork / lb_charge API.
- -cc-mutant accepts 0..15, 17..21; MODIFICATIONS file table merged.
- tests: auto driver configs that stand for the candidate (auto-switch,
  auto-time, auto-time-ubsearch, mutant21-switch, aut-auto-switch) use the
  new default rules (with charge) + tiebreak; flags: default rules +
  tiebreak with -cc-roworder=auto accepted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@guluchen
guluchen changed the base branch from experiment/gh-183-cc-roworder to main October 30, 2026 18:26
…GH-206

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@guluchen
guluchen merged commit 30ce62a into main Oct 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant