windows-boot: report the loss API, fault query and checkpoint counts #1766

Merged
leonida/mandy
sodove merged 1 commit from fix/windows-boot-fault-context into main 2026-11-29 18:28:29 +00:00

Pull request successfully merged and closed

sodove commented 2026-11-25 11:42:53 +00:00

Claimed in the coordination issue as: WIN-BOOT-FAULT-CONTEXT.

Depends on: #1649

What and why

The Windows boot digest now identifies the first recognized Vulkan call that reported device loss and the first recorded device-fault query outcome. It reads late diagnostics as well as the beginning of stderr. The new row uses fixed labels and counts. When the log contains only routine dispatch telemetry, the row is omitted.

The runtime emits one queue header with the driver’s checkpoint count, then one stage record per checkpoint it prints. The row sums the declared counts and counts decoded and unrecognized stage records separately. This preserves the distinction on truncated logs. Optional submission metadata and ordinary ExecuteCommandLists lines do not add checkpoints.

This PR adds the context row to current main. #1649 replaces the existing raw fault excerpts with address-class counts and should land first. The two diffs merge cleanly.

Tested

  • Native Windows 11 and Windows PowerShell 5.1. Six synthetic end-to-end test methods passed through boot.ps1 -DigestOnly. They cover LF and CRLF, truncated and multi-queue reports, missing metadata, unknown operations, runtime fallback markers, and complete, partial, failed and absent query results. The positive cases failed on the base implementation.
  • Merged both changes into a temporary test tree. All six context tests and all five #1649 tests passed. A separate combined-digest check found the expected API, query, address class and checkpoint counts, and zero injected private markers anywhere in the digest.
  • Passed all 39 boot trace tests, 3 text line-ending tests, 16 docs link tests and 16 CI registration tests. The changed-file game-data and Git whitespace checks passed.

GPUs tested: n/a (offline log processing using synthetic inputs).

AI-assisted: yes (OpenAI Codex).

Checklist

  • Based on current main.
  • One topic.
  • No game data, keys or decryption.
  • Translator contract update inapplicable to this reporting change.
Claimed in the coordination issue as: [WIN-BOOT-FAULT-CONTEXT](https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7161231063). Depends on: #1649 ### What and why The Windows boot digest now identifies the first recognized Vulkan call that reported device loss and the first recorded device-fault query outcome. It reads late diagnostics as well as the beginning of stderr. The new row uses fixed labels and counts. When the log contains only routine dispatch telemetry, the row is omitted. The runtime emits one queue header with the driver’s checkpoint count, then one stage record per checkpoint it prints. The row sums the declared counts and counts decoded and unrecognized stage records separately. This preserves the distinction on truncated logs. Optional submission metadata and ordinary `ExecuteCommandLists` lines do not add checkpoints. This PR adds the context row to current main. #1649 replaces the existing raw fault excerpts with address-class counts and should land first. The two diffs merge cleanly. ### Tested - Native Windows 11 and Windows PowerShell 5.1. Six synthetic end-to-end test methods passed through `boot.ps1 -DigestOnly`. They cover LF and CRLF, truncated and multi-queue reports, missing metadata, unknown operations, runtime fallback markers, and complete, partial, failed and absent query results. The positive cases failed on the base implementation. - Merged both changes into a temporary test tree. All six context tests and all five #1649 tests passed. A separate combined-digest check found the expected API, query, address class and checkpoint counts, and zero injected private markers anywhere in the digest. - Passed all 39 boot trace tests, 3 text line-ending tests, 16 docs link tests and 16 CI registration tests. The changed-file game-data and Git whitespace checks passed. GPUs tested: n/a (offline log processing using synthetic inputs). AI-assisted: yes (OpenAI Codex). ### Checklist - [x] Based on current main. - [x] One topic. - [x] No game data, keys or decryption. - [x] Translator contract update inapplicable to this reporting change.
lixonik reviewed 2026-11-25 12:13:43 +00:00
lixonik left a comment
No description provided.
Independent native Windows verification at `4dc7befe`. All six synthetic DigestOnly cases passed in both Windows PowerShell 5.1 and PowerShell 7. I applied #1649 and #1609 to the tested head in a separate checkout. The combined tree applied cleanly and passed the same six cases in both shells again. AI-assisted. Synthetic logs only, with no retail execution or GPU fault capture.
OreoFR commented 2026-11-29 18:03:42 +00:00

TAKEN by OreoFR (Windows, RTX 4070 8 GB)

TAKEN by OreoFR (Windows, RTX 4070 8 GB)
OreoFR commented 2026-11-29 18:09:12 +00:00

Verified by OreoFR — READY

  • Base: main eedd72e30 (includes #2599, LEONIDA_DEVICE_FAULT=2) + this PR (head a79340fae) merged with --no-ff, no conflict; boot.ps1 and the README auto-merge.
  • Red: main + only tests/test_windows_boot_fault_context.py, python -I, Windows PowerShell 5.1.26100: 6 tests, 9 failures (5 tests, all subtests: no fault context: line in the digest). The sixth test (no context for normal dispatches) passes on main, as expected.
  • Green (merge), Windows PowerShell 5.1: test_windows_boot_fault_context.py 6/6 OK, test_windows_boot_fault_digest.py 5/5 OK, test_windows_boot_journal_seed.py 26/26 OK, so #2599's change and this PR live together.
  • PowerShell 7 is not installed on this machine, so no pwsh run here; lixonik's review ran both shells at the earlier head 4dc7befe.
  • Diff read: no game data, synthetic log lines only.
    • Get-FaultContext only runs in the digest, only when the log exists, and adds a line only when it saw a loss, a query outcome or checkpoint records.
    • Labels come from a fixed list of Vulkan API names, so driver text is never echoed; unknown operations show as other.
    • Minor: the log is now read twice (ReadLines for the digest, then Select-String here). Not a blocker.
  • Machine: Windows 11, Intel Core Ultra 7 155H, RTX 4070 Laptop 8 GB, Python 3.12.10, Windows PowerShell 5.1

AI-assisted (Claude Code, Claude Opus 5.5), run for OreoFR.

Ready to merge per the maintainers' plan (green, no conflict, tested).

**Verified by OreoFR** — READY - Base: main eedd72e30 (includes #2599, `LEONIDA_DEVICE_FAULT=2`) + this PR (head a79340fae) merged with --no-ff, no conflict; `boot.ps1` and the README auto-merge. - Red: main + only `tests/test_windows_boot_fault_context.py`, `python -I`, Windows PowerShell 5.1.26100: 6 tests, 9 failures (5 tests, all subtests: no `fault context:` line in the digest). The sixth test (no context for normal dispatches) passes on main, as expected. - Green (merge), Windows PowerShell 5.1: `test_windows_boot_fault_context.py` 6/6 OK, `test_windows_boot_fault_digest.py` 5/5 OK, `test_windows_boot_journal_seed.py` 26/26 OK, so #2599's change and this PR live together. - PowerShell 7 is not installed on this machine, so no pwsh run here; lixonik's review ran both shells at the earlier head 4dc7befe. - Diff read: no game data, synthetic log lines only. - `Get-FaultContext` only runs in the digest, only when the log exists, and adds a line only when it saw a loss, a query outcome or checkpoint records. - Labels come from a fixed list of Vulkan API names, so driver text is never echoed; unknown operations show as `other`. - Minor: the log is now read twice (`ReadLines` for the digest, then `Select-String` here). Not a blocker. - Machine: Windows 11, Intel Core Ultra 7 155H, RTX 4070 Laptop 8 GB, Python 3.12.10, Windows PowerShell 5.1 AI-assisted (Claude Code, Claude Opus 5.5), run for OreoFR. Ready to merge per the maintainers' plan (green, no conflict, tested).
DadaCap commented 2026-11-29 18:28:32 +00:00

Thank you! Merged into main with a merge commit. It was verified ready on its current head (a79340fae) by OreoFR's Windows agent (Windows 11, PowerShell 5.1); see the verification comment above. (AI-assisted, posted for DadaCap.)

Thank you! Merged into `main` with a merge commit. It was verified ready on its current head (a79340fae) by OreoFR's Windows agent (Windows 11, PowerShell 5.1); see the verification comment above. (AI-assisted, posted for DadaCap.)
Sign in to join this conversation.
No description provided.