From 51736fa44faa37fc34009009bf5948af8c3c5564 Mon Sep 17 00:00:00 2001 From: Rongsong Shen Date: Mon, 28 Sep 2026 11:16:31 +0000 Subject: [PATCH] =?UTF-8?q?chore(buglog):=20bug-1881=20partial=20=E2=80=94?= =?UTF-8?q?=20sim-verify=20mismatch=20lines=20name=20the=20first=20differe?= =?UTF-8?q?nce;=20live=20replay=20proof=20pending=20scheduler-sim-discrete?= =?UTF-8?q?-clock?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 (1M context) --- .wolf/buglog.json | 6 +++--- .wolf/bugs/bug-1881.md | 8 +++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.wolf/buglog.json b/.wolf/buglog.json index 077bd838..9ab1f002 100644 --- a/.wolf/buglog.json +++ b/.wolf/buglog.json @@ -16174,9 +16174,9 @@ }, { "id": "bug-1881", - "status": "open", + "status": "partial", "status_updated": "2026-09-28", - "status_note": "logged 2026-09-28; fix not started", + "status_note": "mismatch lines now carry a first-difference diff (24b05718); live default-speed replay proof waits on spec scheduler-sim-discrete-clock (task 5.3)", "component": "scheduler", "severity": "wrong-result", "timestamp": "2026-09-28T07:26:09Z", @@ -16185,7 +16185,7 @@ "error_message": "sim_log_mismatch prints identical expected/actual, hiding the field that differs\n\n**Observed:**\n```\n... MISMATCH ... -- expected: DISPATCH jobid=0-12-1790578108-0[49] nhosts=1 -- actual: DISPATCH jobid=0-12-1790578108-0[49] nhosts=1\n```\n**Expected:** the message names the field(s) that differ, with both values.\n**Impact:** a mismatch cannot be diagnosed from the log (bug-1880: 43 such lines, none showing the difference).\n**Found by:** user reading the bug-1880 replay log, 2026-09-28\n\nUPDATE (2026-09-28): Fix planned in spec libxce-alloc-preason-equality (Requirement 3, Requirement 5.3, task 5): the libxce equality functions gain an optional why/whylen buffer describing the first difference, and sim_log_mismatch appends it to the MISMATCH line.", "file": "src/scheduler/src/sim_verify.c", "root_cause": "sim_log_mismatch() (src/scheduler/src/sim_verify.c) summarizes each decision as kind + jobid + nhosts, while sim_decision_eq() also compares every host's allocations (resname, value, duration, reserve), so a difference there prints two identical summaries.", - "fix": "TODO: required for fixed/partial\n\nVerification:\n- Test: TODO: name + file; RED before the fix, GREEN after\n- Suites: TODO: suite results and build profile\n- Live: TODO: soak/deploy run, or n/a and why", + "fix": "Spec libxce-alloc-preason-equality (commits 8f25c1c3..dcf3acf3). sim_decision_eq() now compares DISPATCH decisions with libxce's public job_alloc_eq() and returns a caller-owned first-difference description (`char** why`) naming the field path and both values; sim_log_mismatch() appends it as ` -- diff: `, and the replay loop in sim_loop.c passes and frees it (fixed text \"no live decision\" for leftover recorded decisions) — 24b05718. job_alloc_eq() also compares `from`, so the scheduler now stamps every allocation's `from` with the deciding session's start (scheduler.c sched_make_primary_alloc_, c1960457) and the normal-mode recorder takes beginRound from the same reading (driver.c, 2d7ba660), making `from` reproducible on replay.\n\nRemaining: the simulator's own session-begin clock read (sim_loop.c) still drifts at --sim-speed >= 1, so a live default-settings replay cannot yet be shown to report zero `from` mismatches. That is task 5.3, blocked on spec scheduler-sim-discrete-clock.\n\nVerification:\n- Test: TODO: name + file; RED before the fix, GREEN after\n- Suites: TODO: suite results and build profile\n- Live: TODO: soak/deploy run, or n/a and why", "tags": [ "scheduler", "sim", diff --git a/.wolf/bugs/bug-1881.md b/.wolf/bugs/bug-1881.md index 2f125820..100ad2ad 100644 --- a/.wolf/bugs/bug-1881.md +++ b/.wolf/bugs/bug-1881.md @@ -1,8 +1,8 @@ --- id: "bug-1881" -status: "open" +status: "partial" status_updated: "2026-09-28" -status_note: "logged 2026-09-28; fix not started" +status_note: "mismatch lines now carry a first-difference diff (24b05718); live default-speed replay proof waits on spec scheduler-sim-discrete-clock (task 5.3)" component: "scheduler" severity: "wrong-result" timestamp: "2026-09-28T07:26:09Z" @@ -43,7 +43,9 @@ UPDATE (2026-09-28): Fix planned in spec libxce-alloc-preason-equality (Requirem sim_log_mismatch() (src/scheduler/src/sim_verify.c) summarizes each decision as kind + jobid + nhosts, while sim_decision_eq() also compares every host's allocations (resname, value, duration, reserve), so a difference there prints two identical summaries. ## Fix -TODO: required for fixed/partial +Spec libxce-alloc-preason-equality (commits 8f25c1c3..dcf3acf3). sim_decision_eq() now compares DISPATCH decisions with libxce's public job_alloc_eq() and returns a caller-owned first-difference description (`char** why`) naming the field path and both values; sim_log_mismatch() appends it as ` -- diff: `, and the replay loop in sim_loop.c passes and frees it (fixed text "no live decision" for leftover recorded decisions) — 24b05718. job_alloc_eq() also compares `from`, so the scheduler now stamps every allocation's `from` with the deciding session's start (scheduler.c sched_make_primary_alloc_, c1960457) and the normal-mode recorder takes beginRound from the same reading (driver.c, 2d7ba660), making `from` reproducible on replay. + +Remaining: the simulator's own session-begin clock read (sim_loop.c) still drifts at --sim-speed >= 1, so a live default-settings replay cannot yet be shown to report zero `from` mismatches. That is task 5.3, blocked on spec scheduler-sim-discrete-clock. ## Verification - Test: TODO: name + file; RED before the fix, GREEN after