Repository navigation
Conversation
|
One thing a reviewer of this pull request should know: it will have no Rust test signal until #2648 lands. The checks on it right now are the general ones ( which is a good measurement and belongs to merzleckeier, not to CI. Nobody approving this should believe the green tick covers it. What that means practically:
I verified what I could without Written with an AI assistant. |
|
Thanks for opening this and crediting the branch. Let's keep the review here. MEASURED. I rebuilt the Win64 CLI test binary from this PR's exact GitHub merge The run used CPU-only fixtures. Hosted native Windows Rust coverage is pending in #2648. AI-assisted with OpenAI Codex. |
|
The #2633 carries the fix and is green on its own. Two ways to clear it here, and I did not take either because this branch is not mine:
The reason it is worth saying out loud: nothing in Still true: Written with an AI assistant. |
3098f5f to
02de330
Compare
|
Rebased onto current What was failing and why: This branch does not touch that test - its only file is After the rebase, on this machine: What the rebase changed: nothing in this branch's own code - the one commit ( What I did not verify: the Rust build. There is no Why I did it rather than asking: the failure was not this branch's, it was its age, and a rebase is the whole fix. If you would rather keep the head you had ( Written with an AI assistant. |
|
RUN - native Windows red/green (Verified by OreoFR) - Intel Core Ultra 7 155H, Windows 11 Pro 10.0.26300, CPU only.
Result: PASS (green). A strict red cannot be built, so I ran a substitute red, described below.
Not covered:
This run was AI-assisted (Claude Code, oreofr-agent). |
|
RUN · VERIFY-2656-RTX4060 · by MoonEyes (another person than the author) on head
AI-assisted (Claude Code). |
`main` gave `child` a store (`--store`, the list in a file because thousands of numbers do not fit a command line) and made its stderr null. This branch reads the child's stderr to notice a stack overflow, so the resolution keeps main's signature and the store, and keeps stderr piped. A null stderr matters beyond the lost diagnostics: `collect_child` takes `(process.stdout, process.stderr)` as a pair and returns early if either is absent, so with main's `stderr(Stdio::null())` this branch would have reported nothing at all rather than everything.
|
done: rebased onto today's
// main's version
fn child(these: &[usize], store: Option<&Path>, mut each: impl FnMut(usize, f64, bool))
...
command.stdin(Stdio::null()).stdout(Stdio::piped()).stderr(Stdio::null()).spawn()The stderr is the whole point of this branch, and not only for the diagnostics: let (Some(out), Some(err)) = (process.stdout.take(), process.stderr.take()) else {
return (total, None);
};so with Verified on the merged tree: The one warning in that build is What I could not test: the behaviour the branch is for - a compiler child hitting its stack guard. That needs the title and a driver that overflows; what I verified is that the merged code compiles and its unit tests pass. AI-assisted: yes - DeepSeek v4.1 (flash), which found the conflict by polling its own pull requests rather than by being told. Written with an AI assistant. |
KelboLive
left a comment
There was a problem hiding this comment.
Reviewed at 2a6dfff4f. The claim matches the code: stderr is piped instead of null (warm.rs:353-359), collect_child matches thread '…' has overflowed its stack, sets the flag and kills the child (:400-407), and the overflow is preferred over the status/hung result once the reader returns (:434-436), so the outer loop marks the pipeline bad instead of waiting out LONGEST. cargo test -p leonida is 50/50 here.
The regression test genuinely guards the early exit: flipping only the matcher suffix makes it fail with (1, Some("hung for 8 s")) against the expected compiler process stack overflow. git merge-tree --write-tree origin/main pr/2656 is clean (9d4a7fd80).
One nit: child() no longer uses each directly, so mut each at warm.rs:335 now warns (variable does not need to be mutable) — drop the mut. The synthetic-diagnostic caveat (the test feeds a crafted line rather than a real overflow) is already stated in the body, and the base being 216 commits behind is harmless here: warm.rs moved only once since then (the count % 1000 → is_multiple_of line), so the logic reviewed is the logic that will land.
|
I followed up on the warm.rs review at I also added a local negative control for stderr matching. A synthetic child prints one line with a warning prefix before the overflow phrase and one with extra text after it, then stays alive. The supervisor still reports MEASURED with the Win64 MSVC target under Wine 11.22, using synthetic subprocesses. No actual stack overflow was required. AI-assisted (Codex). |
Opening this on behalf of merzleckeier, whose account is blocked from opening an upstream pull request at its own open-PR limit (#2621). The branch, the commit and every line of the change are theirs:
fix/warm-stack-overflow-diagnostic,02de3303a("warm: report compiler process stack overflows", rebased from their3098f5ffdonto currentmain). If you would rather open it yourself, say so and I will close this one.What it does
d3d12/apps/leonida/src/warm.rs, one file, +113/-9: theleonida warmsubprocess supervisor reads the child's stderr for Rust's stack-overflow diagnostic (… has overflowed its stack) and, when it sees it, ends the child and reports "compiler process stack overflow" instead of waiting out the no-progress watchdog and calling it a timeout.Why it matters for #2621
The reporter's log says
thread 'main' has overflowed its stackfor 36 of 83,159 pipelines, while the supervisor reports a timeout. Those are two different failures, and a log that cannot tell them apart sends the next reader after the wrong one - which is what happened to me when I first answered the issue.It also matters that this change is not a fix for the pipelines: it makes the failure legible. The compiler-side overflow is still undiagnosed.
Evidence, from the author
Their measurements, quoted rather than repeated as mine: synthetic subprocess A/B where the old supervisor reported a timeout for a child that emitted the overflow line and stayed alive, and the new one reported the overflow and ended the child before the watchdog deadline; removing only the early termination made that regression test fail. The Windows x64 CLI test binary under Wine 11.22 passed 36/36 on the base and 39/39 with the change. The branch adds its test inline in
warm.rs(#[cfg(test)]), so the regression lives with the code.What I checked here, and what I could not
Not verified by me: the Rust tests themselves - this machine has no
cargo, sod3d12/does not build here, and I am not going to claim a green run I did not do. That is also why the body quotes the author's numbers instead of replacing them.AI-assisted: yes - DeepSeek v4.1 (flash) as the coding agent, with a separate reviewer agent reading the change before submission. Where and on what: the measurements above were taken on Windows 11 with MSVC 19.44.35226 on an RTX 4090 (NVIDIA driver 621.24) where a C++ or GPU path is involved; Python and docs cases need none of it.
Written with an AI assistant.