Skip to content

Scripts: the smoke block can't tell a black screen from a working title #717

Backlog

Description

@Chrysana

What happens

A PR can pass the regression check while the title draws nothing. On #541 at 3d7604b (RX 9070 XT), every frame of the 60 s run was black (14 frame captures, 0 % of sampled pixels lit, against main, which is lit from ~21 s on), but its xcl-smoke block looked healthy:

frames shown: 1595 (PresentX 1596)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0

pr_check.py would pass it: more frames than main, lower peak commit. Details: #541 (my comment there; imnicho saw the same on an RTX 5080, and ryosen0 reproduced it on an RTX 3060 Ti: the captures "caught what the smoke block can't"). It is still black at #541's current head 24635db on this card (90 s, empty DXIL cache, 21/21 captures dark), so this isn't a one-off.

Proposal (I'd like to know whether this direction is wanted before writing it)

XCL already has what's needed: XCL_FRAME_DUMP=N samples every N-th frame (its log line already says … – 0 of 518400 samples not black), and report.json keeps the last one as d3d12.last_frame_dump (sampled_pixels, non_dark_samples).

  1. scripts/smoke.ps1 sets XCL_FRAME_DUMP=120 and adds one line to the block from report.json, e.g. lit at end: 100 % (non_dark_samples / sampled_pixels, or n/a when no frame was sampled or the format couldn't be decoded). The block stays xcl-smoke v1; pr_check.py reads key: value lines, so older blocks without the line still parse.
  2. scripts/pr_check.py: when both blocks have the line, refuse a PR whose last frame is dark (say under 1 %) while main's is lit (say over 50 %). Thresholds are up to you; a warning first would also work.

Cost, measured: on main 91f9a5e (RX 9070 XT, 60 s, back to back), XCL_FRAME_DUMP=120 gave 1171 and 1183 frames against 1176 and 1167 without it, which is within run-to-run noise. Each sampled frame writes a quarter-size BMP into the logs folder (10–14 per 60 s run here).

Not covered by this: a title that's black for a legitimate reason at the 60 s mark (a fade, a loading screen); a picture that's lit but wrong. A last-frame check only catches "nothing drawn".

If this is wanted, I'll open a PR for it (smoke.ps1 + pr_check.py + a test of the new line, small).

AI use: Claude Code (Claude Opus 5.5) measured the runs and wrote this issue.

Activity

  1. Luxuryig commented on Nov 24, 2026

    @Luxuryig
    Contributor

    Opened as #747. Thresholds are the ones in the issue: refuse when the PR frame is under 1% and main is over 50%. A missing line or n/a still passes.

  2. OrangeCrane1738 commented on Nov 24, 2026

    @OrangeCrane1738

    Another case the check lets through, from regression runs I made today: both runs died about a second after starting and still produced blocks the check accepts.

    On this PC (no Gaming Services), builds without #235 route XAsync to a system runtime that failed to initialise (XGameRuntime PC: initialization → 0x80070424, then XAsync: PC). On main beaa245 and on #821's head f9ef768 the title then stopped about a second in with a fail-fast (Windows' "stack-based buffer overrun" dialog). The log shows only empty activity lines after that until XCL_RUN_SECONDS ended the run at 25 s. Both blocks (RTX 5060 Ti):

    exit: 0x0
    frames shown: 0 (PresentX 0)
    presents per 2 s (last 3): 0 0 0
    device removals: 0
    crashes: 0
    

    Two things let it through:

    • smoke.ps1 counts crashes from unhandled exception|process ends with status; a fail-fast never reaches XCL's handler, so it reads 0.
    • pr_check.py compares frames only if mf: when main's block shows 0 frames the comparison is skipped, so two dead runs pass.

    Requiring main's block to show frames (or at least warning when either block shows 0) would catch this, alongside the lit-pixel check proposed here.

    AI use: Claude Opus 5.5 (in the Claude app) helped analyse the logs and draft this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions