Repository navigation
Conversation
smoke.ps1 sets XCL_FRAME_DUMP=120 and adds `lit at end` from the last sampled frame. pr_check refuses a dark frame when main's is lit. Fixes xcl-dev#717 Assisted-by: Grok Build (Grok 4.7)
|
Tested exact head Tested
Not tested
AI use
|
|
The new frame-dump setting leaks into the caller when process startup fails on With the caller's 52de2df sets Tested
Workspace result
Not tested AI use Current-main integration follow-upIntegration head a62d547 combines Tested
These are script checks with our own small C fixture, not title runs. No proprietary files or new smoke blocks. Rust/GPU tests were not rerun for this scripts-only integration. The separate rounding concern raised by @136084599 is unchanged. AI use: Codex (GPT-6; exact variant unavailable) resolved the integration, reapplied the existing fix, ran the checks and prepared this update. |
|
Independent Windows check of The one-decimal formatting can round a measurement onto either strict cutoff. With 518,400 samples per report:
Both would be rejected by the stated AI-assisted. Synthetic reports only, no XCL or retail run. Follow-up: patch and two boundary tests The added sub-1% fixture fails on fd323c0 before the formatter change. With the patch below, all nine PowerShell fixtures pass on PowerShell 7.6.9, and all seven Python checker tests still pass. Git also accepts the patch against the pinned files. This only uses synthetic reports. diff --git a/scripts/smoke_lit.ps1 b/scripts/smoke_lit.ps1
index 4c6c5a8..9172bb0 100644
--- a/scripts/smoke_lit.ps1
+++ b/scripts/smoke_lit.ps1
@@ -12,5 +12,5 @@ function Get-XclSmokeLit([string]$Report) {
if ($pixels -le 0) { return 'n/a' }
$pct = 100.0 * [int64]$dump.non_dark_samples / $pixels
# A comma decimal would not parse in pr_check.py, so the line is always dotted.
- return ([string]::Format([Globalization.CultureInfo]::InvariantCulture, '{0:0.#} %', [double]$pct))
+ return ([string]::Format([Globalization.CultureInfo]::InvariantCulture, '{0:0.########} %', [double]$pct))
}
diff --git a/scripts/test-smoke-lit.tests.ps1 b/scripts/test-smoke-lit.tests.ps1
index 82673e3..269a04d 100644
--- a/scripts/test-smoke-lit.tests.ps1
+++ b/scripts/test-smoke-lit.tests.ps1
@@ -22,6 +22,10 @@ try {
Assert-Eq 'black' (Get-XclSmokeLit $report) '0 %'
Write-Report 1000 4
Assert-Eq 'fraction' (Get-XclSmokeLit $report) '0.4 %'
+ Write-Report 518400 5132
+ Assert-Eq 'just below one percent' (Get-XclSmokeLit $report) '0.98996914 %'
+ Write-Report 518400 259252
+ Assert-Eq 'just above fifty percent' (Get-XclSmokeLit $report) '50.01003086 %'
Write-Report 1000 $null
Assert-Eq 'undecoded' (Get-XclSmokeLit $report) 'n/a'
Write-Report 0 0 |
|
Thanks for picking up #717. This is the retail check I offered there: Tested
The black build shows more frames than
Worth knowing
Not tested
AI use
|
sds-228
left a comment
There was a problem hiding this comment.
Reviewed head fd323c0. Locally: python scripts/test_pr_check.py → 7 passed, 0 failed; powershell.exe -NoProfile -File scripts/test-smoke-lit.tests.ps1 → passed. The JSON fields read by smoke_lit.ps1 (sampled_pixels, non_dark_samples) exist in present.rs.
Blocking: mergeable: false, mergeable_state: dirty. A dry-run merge of current main into this head conflicts in scripts/test_pr_check.py. Please rebase and re-run the script tests.
Question: smoke.ps1 now sets XCL_FRAME_DUMP=120, which adds a quarter-resolution readback every 120 presents. The description says smoke.ps1 was not launched. Is there evidence this does not move the smoke counters used by PR-check thresholds?
Also note #1229 changes the same test file; recheck that interaction after both land.
AI-assisted (OpenCode).
|
@sds-228 On the
So on this card the cost is within run-to-run spread. That's one GPU and a handful of runs, so it doesn't rule out a cost on slower cards, where the readback takes a bigger share of each frame. (Claude Code, Claude Opus 5.5) |
All console view heaps share one shader-visible PC heap, a page of 256 slots (512 descriptors) at a time. On NVIDIA it holds 1 000 000 descriptors, and the only line about its fill was the warning when it is completely full, so a log could not show how close a title gets. The newer retail title makes a view heap of 1 245 184 slots. Another project (VIctory xcl-dev#747, RTX 4070 Ti) measured about 1.1M of its slots written and its descriptor tables reaching the top of the heap. Whether that costs XCL pages depends on how the slots are written (device calls or memory copies), which no log shows today. The shared heap now counts the descriptors and pages it gives out and logs once, the first time each of 25 / 50 / 75 / 90 % is reached: console descriptor heaps: the shared heap is 25 % full – 250368 of 1000000 view descriptors given out, 489 pages placed, high-water mark 250368 The levels are of the descriptors given out. The line also gives the high-water mark, because the full warning comes from that: released ranges go to a first-fit list that is not merged, so the heap can be full before every descriptor is given out. The check runs only when a page is placed, not per slot. The XCL_TRACE_FRAME view-heap census line also says how many of each heap's pages are placed in the shared heap. No behaviour change. Assisted-by: Claude Code (Claude Opus 5.5)
All console view heaps share one shader-visible PC heap, a page of 256 slots (512 descriptors) at a time. On NVIDIA it holds 1 000 000 descriptors, and the only line about its fill was the warning when it is completely full, so a log could not show how close a title gets. The newer retail title makes a view heap of 1 245 184 slots. Another project (VIctory xcl-dev#747, RTX 4070 Ti) measured about 1.1M of its slots written and its descriptor tables reaching the top of the heap. Whether that costs XCL pages depends on how the slots are written (device calls or memory copies), which no log shows today. The shared heap now counts the descriptors and pages it gives out and logs once, the first time each of 25 / 50 / 75 / 90 % is reached: console descriptor heaps: the shared heap is 25 % full – 250368 of 1000000 view descriptors given out, 489 pages placed, high-water mark 250388 The levels are of the descriptors given out to view heaps' pages. The line also gives the high-water mark, because the full warning comes from that: it counts the 20 descriptors below the pages (null views and the memory windows' views), and released ranges, though merged, can leave gaps too short for a page, so the heap can be full before every descriptor is given out. The check runs only when a page is placed, not per slot. The XCL_TRACE_FRAME view-heap census line also says how many of each heap's pages are placed in the shared heap. No behaviour change. Assisted-by: Claude Code (Claude Opus 5.5)
Fixes #717.
scripts/smoke.ps1turns on the existing frame sample (XCL_FRAME_DUMP=120) and addslit at endto thexcl-smoke v1block: the last sampled frame's non-black share, orn/awhen nothing was sampled or the format was not decoded.scripts/pr_check.pyrefuses the PR when both blocks have a number, main is over 50 %, and the PR is under 1 %. A missing line orn/ais left alone, so older descriptions and short runs still pass. A main frame at 50 % or under does not fail a dark PR.Scripts only.
.github/workflows/pr-check.ymlrunspr_check.pyfrom main (pull_request_target), so the new refusal starts after this merges. The line is in the block immediately.scripts/smoke.ps1will conflict with #704 and #689. Those change the title line; this adds the lit line and setsXCL_FRAME_DUMP.What is in it
scripts/smoke.ps1: setXCL_FRAME_DUMP=120for the child (the caller's previous value is restored) and printlit at end.scripts/smoke_lit.ps1: readd3d12.last_frame_dumpfromreport.json. The percentage uses a dot, not the locale's decimal mark.scripts/pr_check.py: refuse a dark last frame against a lit main.scripts/test_pr_check.pyandscripts/test-smoke-lit.tests.ps1: the threshold and the percentage line.Tested
C:\Program Files (x86)\Windows Kits\10\bin\10.0.26100.0\x64..\scripts\test.ps1on63cdc25plus these script files, before the rebase onto64b3f35: exit 0. 692 passed, 0 failed, 41 ignored. GPU tests skipped: 2 (no wave64). Unset, so their tests skipped:XCL_SAMPLE_RPF,XCL_SAMPLE_DLLS,XCL_SAMPLE_TTPF,XCL_SAMPLE_BK2,XCL_SAMPLE_BVH4,XCL_SAMPLE_AWC,XCL_SAMPLE_XG,XCL_SAMPLE_DXC.tests/e2e.rs: 3 passed. Wall time 138.98 s. Not re-run after rebasing onto64b3f35(origin/mainat the time of the push). Anothercargobuild was already using the machine, and this diff does not change Rust.python scripts/test_pr_check.py: Ran 7 tests, OK. The new cases:0 %against main80 %is refused,0.4 %against60 %is refused,90 %against80 %passes, and a missing line,n/a, and main at40 %are left alone.powershell.exe -NoProfile -File scripts/test-smoke-lit.tests.ps1:smoke lit tests passed(100 %,0 %,0.4 %, undecoded, no samples, no dump, missing file).Regression run
crates/xcl/srcis untouched, so there are noxcl-smokeblocks.Not tested
smoke.ps1was not launched. The in-tree test title exits in about 2 seconds after about one present, so a sample every 120 frames (presents % 120 == 20) would not fire andlit at endwould ben/a. The percentage is checked against a writtenreport.json, not a captured frame.pr_check.pyis on main.AI use