Repository navigation
xbox_present: a skipped present after a resize is not a composition failure (and the helper says which step failed) - #2652
Conversation
fd743b4 to
e93efd8
Compare
|
Rebased onto The change itself is unchanged and still verified on this machine ( Written with an AI assistant. |
|
Independent
MEASURED. The base failed at the first resize capture in case F. #2652 retried once at each of the three resizes. With #2507 present, all runs finished with zero helper retries. Both patches apply cleanly together. MEASURED, negative control. On the second iteration of the first resize, I fed the size checker a byte count one texel short after a successful readback from a present that advanced the shown counter. The existing helper reported a skipped present, retried, and the full test passed 3/3 per GPU. The same control failed at the readback on both GPUs in 3/3 runs when I allowed the retry only in case F and only if
Synthetic fixtures only. AI-assisted with OpenAI Codex. |
|
Re-verified on the current
With this branch applied ( So Nothing else changed in the branch: the diagnostics in the first commit and the one-shot retry in the second are what they were, and the 539-test run shows no new failure anywhere else. Written with an AI assistant. |
e93efd8 to
1a0cc76
Compare
It returned false for a missing frame token, a wrong HRESULT and a failed read-back, so a failing EXPECT pointed at a lambda that could have failed three ways. On this machine the read-back is the one that fails after the window resize (case F), and it took a rebuild to find that out. Written with an AI assistant.
…ailure Case F resizes the window and demands a capture from the next present. The layer is allowed to skip one - its own contract says VK_SUCCESS covers "a skipped present (minimised window) and one the surface reported out of date" - and it sets captured_ = false when it does, so read_back() returns false and the EXPECT failed. Retry once: the following present shows the frame. Verified on this machine, where the failure reproduced: three runs exit 0 and ctest reports xbox_present Passed. Before the change the same binary failed at line 1335 with "read-back failed", three times. Written with an AI assistant.
1a0cc76 to
cce63b2
Compare
|
Re-verified after the rebase onto What I did not test: the rest of the change, and anything the rebase did not touch. This confirms the rebase kept the change working, not that the change is correct - that is what the review and the CI are for. Written with an AI assistant. |
|
Independent check on Windows/NVIDIA (not the author), at
It then fails at Net: the resize/composition fix is confirmed here; the remaining failure is environmental. A run with an active desktop should confirm the pacing assertion. AI-assisted: yes (opencode). |
|
Measured end to end on the current A full And the single test, both ways: So the red is not flaky and not this machine: it is one test in the suite on today's What that means for the merge decision, which is yours: What I could not test: the other half of your report - AI-assisted: yes - DeepSeek v4.1 (flash) ran the suite and the single test on the machine above. Written with an AI assistant. |
|
finding: re-verified on today's
What the fix did, and it is a real improvement: the What it still fails on, and I have four runs to show it is not one thing: So on one run the 2-plane composite present ( What I could not do: name the third path. What I would suggest: the failing AI-assisted: yes - DeepSeek v4.1 (flash), four runs and a build. Written with an AI assistant. |
|
Narrowed further, so whoever picks this up starts where I stopped rather than where I started. The file has exactly two L37 if (!(condition)) { std::fprintf(stderr, "line %d: %s\n", __LINE__, #condition); return 1; }
L1565 std::fprintf(stderr, "%u validation errors (%u known sRGB swapchain checks)\n", ...); return 1;And the three end paths print too ( Where the binary actually stops: So it dies somewhere between L623 and L1553 without going through any exit path in What that leaves as candidates, in the order I would look:
I am not going to guess further: AI-assisted: yes - DeepSeek v4.1 (flash). Written with an AI assistant. |
|
finding: this pull request no longer fixes anything on
And with this branch applied, two hours ago on So the two trees fail identically at L634, and the What I am now recommending, and I would rather correct myself than leave it: close this, and open the L634 failure as its own item. The assertion is exact and narrow: EXPECT(xbox.PresentX(2, two, nullptr) == S_OK);
EXPECT(xbox.presenter().composed_presents() == composed_before); // plane 1 has no overlay flagA 2-plane composite present is incrementing And the three-runs-in-four silent exit is a second finding: no AI-assisted: yes - DeepSeek v4.1 (flash), which reported this as an improvement two hours ago and is correcting itself after rebuilding Written with an AI assistant. |
|
finding: both arms of the test are identical with and without this branch, and the reason I kept seeing a difference is that I was running the wrong one.
And there are two different failures, one per arm. Measured on Identical, line for line, in both arms. So this branch changes no outcome at all. The That is the third version of this report, and the two earlier ones were wrong for the same reason: I compared a run against a run, without checking which arm each one was. What this branch is worth: its What the two failures need, and neither is this branch: the 2-plane composite present incrementing I would still close this as a fix and keep the helper if it is useful, but whoever reopens it should start from the two arms above. AI-assisted: yes - DeepSeek v4.1 (flash), which reported this pull request as a fix twice and is correcting itself twice. Written with an AI assistant. |
|
closed: both arms of The measurement, on
What the branch did do: its The two failures, for whoever picks them up, and neither is in this branch:
Where to track them: #2464 is the game-run work and already carries this test; #2570 is the coordination issue. I did not open a new issue for either because I do not know which of the two a maintainer considers the bug and which the test's expectation - the counter or the call site. AI-assisted: yes - DeepSeek v4.1 (flash), which reported this pull request as a fix twice and closed it after measuring both arms. Written with an AI assistant. |
This now fixes the failure, not just reports it. Two commits: the diagnostics that found it, and the retry that repairs it.
The failure
xbox_presentfailed on this machine atline 1320(now:1335) with no indication of which step went wrong.present_planesreturnedfalsefor three different reasons and said none of them. It now names the step:The cause
Case F resizes the window (
400x300 -> 200x150 -> 320x240) and asks the next present for a capture. The layer is allowed to skip that present and still report success - its own contract inruntime/src/vulkan_present.hsays "VK_SUCCESSalso covers a skipped present (minimised window) and one the surface reported out of date" - and when it does it setscaptured_ = false(:511), soread_back()refuses (:366:if (!capture_ || !capture_ptr_ || !captured_) return false;).So the test demanded a capture from a present the layer may legitimately skip. The test's own comment at
:1316shows the author expected the size to lag after a resize, but what it did not tolerate is a skipped capture.The change
In
present_planes, when the read-back fails, present once more and try again:The retry runs only on the failing path, so a passing present is untouched.
Tested
On this machine, where the failure reproduced before the change:
Re-verified on the current
main(1d22590b9) after the tree moved, because a fix measured against an older base can stop being true:and the same binary failed three times at
line 1335before it, and no other C++ test fails in either run.Not tested
Nothing outside this machine. The disposal is the interesting part: a real desktop may never hit the skip, and this change is a no-op there - it only fires when the read-back fails, which is precisely the case that used to turn into a false composition failure.
The extra commit at the tip (no longer carried)
The branch used to carry
a3b5ebea1(test(semantic): align computed-I/J f16 interp oracle…), added only becausesemantic-testswas red onmainfor that oracle and every branch cut frommaininherited it.mainnow has the same edit asc717967d0, so a rebase drops the commit and this pull request no longer touchestests/semantic/test_interp_computed_ij_fallback.py- the diff is only what this change actually needs.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.