Give the AOT draw harnesses a timeout that survives ctest -j8 #1434
No reviewers
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows!1434
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1434"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@FoxxoOwO on GitHub · 2026-11-24 11:29 UTC · original
FoxxoOwO:test/aot-timeout-contention→main· +10 −0 · 1 files · 3 commits · openWhat
Four AOT translate-and-draw tests fail as
Timeoutunderctest --preset dev -j8while every one of them passes when run alone:compute_store_aot_guard_read_hardwarecompute_store_aot_lds_arithmetic_hardwarecompute_store_aot_lds_qword_hardwarepixel_aot_blend_scalar_hardwareEach of these harnesses compiles a shader with DXC and then drives the adapter, so when seven siblings time-share one physical GPU the wall clock roughly doubles and trips a budget sized for a lone run. The assertions never execute — the compiler and the draw are still queued. Nothing about the translated code is being reported.
Change
The 93
compute_store_aot_*andpixel_aot_*hardware tests get a 180 s budget from one block appended toCMakeLists.txt:Three to four times the contended run, still short enough to catch a hang. The warp variants keep their budgets and no assertion is touched — this PR only moves a timing budget.
Measured
Rejected alternative
RESOURCE_LOCK gpuon all hardware tests fixes the same four tests, and I measured it: 1120 s for the 244-test hardware subset, up from 270 s, because 244 tests then queue behind one adapter. Not worth it for four flaky budgets.Notes for review
--timeoutflag does not override a per-testTIMEOUT(measured:--timeout 6withpixel_aot_blend_scalar_hardwarestill passes in 26.7 s), so the per-test property is the only budget that matters..github/workflows/windows.ymlruns ctest without-jand excludes_hardware$, so no CI job can observe this change.-Rselection would still fail because the commands in this repo use--no-tests=error; the block adds properties only.Environment
MSVC 19.44.35230.0 · Windows SDK 10.0.22621.0 (DXC 1.6.2112.16) · NVIDIA GeForce RTX 3070 Ti, driver 32.0.16.2124, debug layer unavailable · Windows 11 · 8-way
ctest -j8.@Makto94 on GitHub · 2026-11-24 14:59 UTC · original · edited 2026-11-24 15:49 UTC
Withdrawn — see my correction below. The serial-timeout conclusion and the pass/skip totals in this comment are wrong.
Independent hardware data point for this change (main at
800a4500, before this PR).ctest --preset dev --no-tests=error -R '_hardware$' -j1 --timeout 120Result: 246 passed, 36 capability skips (77), 2 Timeout at the 60 s budget:
pixel_aot_hardware(60.03 s) andpixel_aot_core_vector_hardware(60.10 s).Rerunning
pixel_aot_hardwarealone: Passed in 26.97 s, every readbackmax_absolute_error=0.So the 60 s budget also trips on a serial (
-j1) run, not only under-j8.@ChazY11 on GitHub · 2026-11-24 15:05 UTC · original
The pattern catches exactly the 91 hardware draw harnesses, and nothing else
Independent reviewer, not the author. Reviewed the current head; nothing pushed to the branch.
Environment: Windows 11 build 26300.9974, MSVC 14.44.35207, SDK 10.0.26100.
I read the registered properties out of CTest rather than trusting the pattern:
So every harness the comment describes is raised, and no test was missed by the alternation. I also checked the two things
the pattern could have caught by accident:
pixel_aot_warp/compute_store_aot_*_warp— not matched, because the pattern anchors on_hardware$, and the_warpcases keep their shorter timeouts. Correct: they do not contend for a single adapter.pixel_aot_hardwareitself (no subgroup) — matched, which is right; it is the same harness.One consequence worth stating in the comment
With 91 cases at 180 s, a genuine hang in one of them now costs up to three minutes instead of under one, and a systematic
hang across the group costs far more when they run serially. That is a fair trade for the timeout flake, and since these
are
_hardwarecases the CI job never runs them — but if someone later adds_hardwareto a job, the worst case growswith the count. Not a change I am asking for; the comment already says "still catches a hang", and 180 s does.
Verdict
Reviewed the current head. The timeout applies to exactly the intended set, the
_warpcases are untouched, and therationale in the comment matches what I measured. No objection from me.
@Makto94 on GitHub · 2026-11-24 15:49 UTC · original
Correction to my earlier comment: I withdraw its conclusion that the 60 s budget also trips on a serial (-j1) run.
Reason: I started a package installation (winget) on the same machine shortly after the sweep had finished 193 of 284 tests. The two timeouts are the next two tests,
pixel_aot_hardwareandpixel_aot_core_vector_hardware. I have not shown that this caused the timeouts.The totals I gave for the first run were miscounted. The real totals are 264 passed, 18 skipped, 2 timeout (284 tests).
Idle rerun, same command and same commit (main at
800a4500):ctest --preset dev --no-tests=error -R '_hardware$' -j1 --timeout 120, with no build, installation or other test run in parallel.Result: 266 passed, 18 skipped, 0 failed, 0 timeouts (284 tests). The 18 skipped tests have the same names as in the first run.
pixel_aot_hardware(734) passed in 24.93 s andpixel_aot_core_vector_hardware(735) in 14.23 s.Two isolated runs of tests 734 and 735 gave 24.97 s and 14.16 s, then 24.94 s and 14.20 s. All passed.
Adapter: NVIDIA GeForce RTX 3070 Ti, driver
32.0.16.2101(NVIDIA 621.01). Debug layer unavailable on this machine (debug_layer=unavailable).In an undisturbed
-j1run both tests pass well inside 60 s; I have not run the-j8sweep that is your acceptance check.@christiancoleman on GitHub · 2026-11-24 16:45 UTC · original
Independent data point for the requested revision (per-registration budgets for the cases a
-j8sweep names). Not the author; nothing pushed.Environment.
mainatcb94b8ca, before this PR. Windows 11 build 26300.9974, MSVC 19.51.36248 (VS 18 Community), Windows SDK 10.0.26100, DXC from that SDK, Python 3.14.3. One physical adapter: NVIDIA GeForce RTX 4090 Laptop GPU (vendor 10de, device 2717), driver 32.0.16.2124, debug layer enabled.Sweep.
ctest --preset dev --no-tests=error -j 8over the whole registered suite (1022 tests): 1003 passed, 19 capability skips, 18Timeout. Rerun of the 18 withctest --preset dev --no-tests=error --rerun-failed(serial,-junset): 18 of 18 passed in 546 s total. Partial output of every timed-out case already showedmismatches=0anddebug_errors=0before ctest killed it, so none is a fixture failure.The sweep names 14 cases beyond the four in the PR description, plus one outside the
^(compute_store_aot|pixel_aot)pattern:compute_store_aot_hardwarecompute_store_aot_guard_read_hardwarecompute_store_aot_lds_private_hardwarecompute_store_aot_lds_arithmetic_hardwarecompute_store_aot_lds_qword_hardwarecompute_store_aot_lds_f32_hardwarecompute_store_aot_mtbuf_store_hardwarepixel_aot_hardwarepixel_aot_cmpx_regions_hardwarepixel_aot_cmpx_e64_hardwarepixel_aot_predicate_rounding_hardwarepixel_aot_comparisons_hardwarepixel_aot_blend_scalar_hardwarepixel_aot_shift64_hardwarepixel_aot_e64_hardwarepixel_aot_cvt_f64_f32_hardwarepixel_aot_cvt_int_f64_hardwaresampled_coverage_hardwareDeclared budgets come from
ctest --preset dev -N --show-only=json-v1; serial times from the rerun output andCTestCostData.txt.Observations.
guard_read38.9 of 45 s,lds_qword35.3 of 45 s,cvt_f64_f3237.6 of 60 s), so a 2x contention slowdown trips them on this adapter even though the 3070 Ti sweep did not name them.sampled_coverage_hardwareis not covered by the PR's pattern and is the longest case here at 78 s serial against 150 s. Worth a look if the per-registration list is being assembled._hardwareset on this machine was not measured separately; the number above is the mixed suite.Happy to rerun a candidate branch with the same
-j 8sweep on this adapter.@R0Y00 on GitHub · 2026-11-26 04:43 UTC · original
The targeted timeout changes at
54fb63b0address my scope comment, and the Windows Debug and Release checks passed for the eight named variants. @christiancoleman, if your RTX 4090 Laptop is available for the contention rerun you offered, please repeat the same -j8 sweep on this head and list timeouts separately from capability skips. Please rerun any timeout by itself and record the elapsed time. That gives us a comparison with your earlier run and shows whether any of the three changed registrations still times out.@tedin7 on GitHub · 2026-11-24 12:29 UTC · original · reviewed
Dual-platform review of PR #1434 at commit
7a62000259de999cfde968324433841472e2b6fa:Code & Scope Audit
CMakeLists.txtappends a loop overDIRECTORYTESTSmatching^(compute_store_aot|pixel_aot)(_.*)?_hardware$and setsTIMEOUT 180._hardwaretests are affected;_warpvariants,SKIP_RETURN_CODE 77,ENVIRONMENTproperties, and non-AOT hardware tests remain unchanged.compute_store_aot_*_hardwareorpixel_aot_*_hardwaretests added after this block inCMakeLists.txtwould not be covered, so keeping this block at the end ofCMakeLists.txtis appropriate.Verification
git diff --check origin/main...HEAD: passedpython3 -B tests/docs_links_check.py: passed (16 Markdown files, 301 links)python3 -B tests/bidi_controls_check.py: passed (1145 files)--preset dev):cmake --build --preset dev --target offscreen_check -- -j 6(10.06s),ctest --preset dev -R '^compute_store_aot_warp$' --parallel 4 --no-tests=error --output-on-failure: 1/1 passed (5.51s)./O2(--preset release):cmake --build --preset release --target offscreen_check -- -j 6(7.56s),ctest --preset release -R '^compute_store_aot_warp$' --parallel 4 --no-tests=error --output-on-failure: 1/1 passed (5.46s).ctest -j8 -R '_hardware$'on a physical GPU (this VM only has D3D12 WARP).@R0Y00 on GitHub · 2026-11-24 13:11 UTC · original · requested changes
The four contended timeouts and the two clean hardware sweeps are useful evidence. Please start by increasing the budget at the registrations for those four cases. The final blanket override also replaces future per-test budgets and extends the detection time for unrelated hangs. Keep the same -j8 hardware sweep as the acceptance check, and add any other case only if the sweep names it.
@tedin7 on GitHub · 2026-11-26 04:20 UTC · original · reviewed
I pushed the change requested in the review (merged
main, no rebase, then one commit on top).foreachoverride at the end ofCMakeLists.txt.compute_store_aot_lds_arithmetic_hardware,compute_store_aot_lds_qword_hardware,pixel_aot_blend_scalar_hardware(CMakeLists.txt, next to eachadd_test).compute_store_aot_guard_read_hardwarealready has 180 s onmain, so it needed no change. Warp variants and all other budgets are untouched.Verification (Windows Server 2025, MSVC 14.44, D3D12 WARP + hardware adapter), PR head plus this change:
ctest --preset dev -R '^(compute_store_aot_guard_read|compute_store_aot_lds_arithmetic|compute_store_aot_lds_qword|pixel_aot_blend_scalar)_(hardware|warp)$' --parallel 2 --no-tests=error: 8/8 passed.--preset release: 8/8 passed.ctest -j8hardware sweep that you named as the acceptance check. Runs here were not under 8-way contention, so they show the change is safe, not that the contention timeouts are gone.@R0Y00 could you re-review? @FoxxoOwO thanks, feel free to adjust.
AI-assisted; commands listed were executed locally.
@JohnConnorNPC on GitHub · 2026-11-28 07:58 UTC · original
Thanks for the per-registration budgets. I reviewed head
54fb63b0(independent reviewer, not the author). Two requests before this is ready, plus two small notes:Checked, OK
set_tests_properties(<x>_hardware PROPERTIES TIMEOUT 180)blocks after each registration, and the blanket override is gone (git diff 62946ccf 54fb63b0 | grep -c 'PROPERTY TESTS'→0).guard_read_hardwarewas already 180 s at the merge-base.mainis clean (git merge-tree --write-tree origin/main 54fb63b0→ rc=0), and no later line onmainresets TIMEOUT for the three tests.windows.ymlrunsctest … --parallel 4 -E '_hardware$'.Requested
-j8hardware sweep on this head, has not been posted yet. The review note for the head commit says "Not run: the fullctest -j8hardware sweep that you named as the acceptance check". If you have an adapter you can run it on, please post it with timeouts listed separately from capability skips, and rerun any timeout alone with its elapsed time. The earlier RTX 4090 Laptop sweep ofmain(cb94b8ca,-j 8) reported 18Timeout; 14 of those are not covered here (for examplecompute_store_aot_hardware,pixel_aot_hardware,sampled_coverage_hardware). Either add the cases the sweep names, or note that the maintainer has ruled them out of scope.7a620002) still describe the removed approach: "The 93compute_store_aot_*andpixel_aot_*hardware tests … get a 180 s budget from one block", plus theforeachloop. Please squash and rewrite both to describe the three per-registration budgets, so the merge history matches the diff.Notes (optional)
ctest -j8the hardware run time-shares the adapter and roughly doubles."). A short comment on the qword and blend_scalar hunks, or a pointer to the first, would help.This comment was AI-assisted.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.