Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Test results

2026-11-05: Zero mode keeps memory committed

patches/ghostty/0001-* Win7 zero mode is now memset of the dirty prefix then VirtualAlloc(MEM_RESET), replacing decommit/recommit (no recommit, no panic path).

  • OOM test (now asserts the new contract). 64 MiB Job Object quota plus a competing allocator thread: 256 rounds of fill, zero decommit, full zero check and recommit. The helper committed 0 bytes throughout and the quota stayed exhausted. Child exit 0 in 1,094 ms, no panic, no VM effect.
  • Full Win7 x64 rerun. Ghostty suites: 3,316 + 3,803 passed, 35 + 35 skipped, 0 failed. The 60 s wait/wake stress test made 5,252,055 handshakes and passed. The memory reset test passed on 1,600 ranges in both modes.
  • Native corpus: 40 cases, 0 failures.

2026-11-05: Zig patch without the x86 branch, and the out-of-memory recommit test

  • Zig patch 7b9439f. The 8-byte compare is now a single atomic u64 load. The Ghostty suite ran against a freshly rebuilt view of the Zig lib, which contains the new code (27694ed fixed the stale-view bug). Win7 x64 results: 3,316 + 3,803 passed, 35 + 35 skipped, 0 failed. The 60 s wait/wake stress test made 5,108,600 handshakes and passed. The memory reset test passed on 1,600 ranges.
  • Out-of-memory recommit test (53df1cf). The test runs in a child process capped at 64 MiB by a Job Object. A real recommit failure happened on attempt 4. The child exited with code 3 in 31 ms, printing terminal memory recommit failed. There was no hang, no access violation, no error dialog, and no effect on the VM. See tests/win7/REPORT.md.

2026-11-05: x64-only rerun

Voyager7 is now x64-only. This rerun is against the build with all x86 targets, helpers and 32-bit goldens removed, and with the 32-bit test patch dropped.

  • Import check: OK for ghostty-vt.dll, vt_harness.exe, and every test exe.
  • Corpus: Linux 40/40. Win7 x64 40/40.
  • Ghostty lib-vt suite, Win7 x64: 3,316 + 3,803 passed, 35 + 35 skipped, 0 failed (7,119 passed in total).
  • Wait/wake stress: 60 s with 64 threads, 512 addresses and 1/2/4/8-byte widths: 4,237,592 handshakes, all passing.
  • Memory reset: 1,600 ranges in both modes, with 3,307 MiB of background pressure, all passing.

2026-11-05: wait/wake stress and memory reset on Windows 7

Runtime probes pass on x64 and x86; full-suite x86 failures are documented. Both architectures completed 60.063 seconds of mixed 1/2/4/8-byte waits across 512 address words with 64 threads, 32,000 mutex/condition turns with 16 threads, and 1,600 memory ranges in both reset modes. The pressure thread obtained 3,273 MiB on x64 and 1,200 MiB on x86. No replacement-patch defect was found.

The complete Ghostty test step gives x64 7,119 passed, 70 skipped, 0 failed, and x86 7,091 passed, 74 skipped, 24 failed, with zero tests left unrun and zero leaks. The x86 failures are 22 native-layout expectations plus two instances of an upstream malformed-snapshot capacity-validation overflow. This decoder bug remains unfixed. The production Win7 patches are unchanged; the import checker now rejects two additional missing APIs discovered by a safe export probe.

See the full report, actual runner output, and reproduction instructions. Recommit failure under forced commit exhaustion was not tested. The final suites use ReleaseSafe with slow safety enabled; the earlier Linux baseline used Debug.

2026-11-05: harness scrollback coverage (VT-HARNESS 2)

Result: pass. All 40 cases pass on Linux (64-bit and 32-bit) and on Win7 (x64 and x86). Full VM output is in docs/test-results/2026-11-05-scrollback-win7.txt.

  • New in the dump: full scrollback rows with styles, widths and wraps, compared in both the one-shot and the chunked feed.
  • 13 new cases: styled history, a partial DECSTBM region, line and byte limits, disabled history, alternate screens, DECSC/DECRC, 1048 and 1049, ED 3, and resize with reflow.
  • API gap: the pinned public C API can't read the inactive screen or the saved cursor. The dump prints unavailable public-api for them, and the restore cases cover them indirectly.
  • 32-bit results differ, and that's correct. Scrollback limits are byte budgets, and 32-bit pages hold more rows. 27-stress keeps 2,091 rows on 32-bit and 1,122 on 64-bit, and 30-scrollback-limit keeps 314 and 329. tests/corpus/expected-32/ holds the 32-bit Linux results for those two cases, and the Win7 x86 output is byte-identical to them. The first VM run compared x86 against the 64-bit results, so it reported these two cases as failures (38 of 40). That run is kept in the log file above.

2026-11-04: libghostty-vt on Windows 7 (roadmap step 1)

Result: pass. All 27 corpus cases pass on Windows 7 for both x64 and x86. Each dump matches the Linux golden byte for byte.

Voyager7 commit60c5058
Ghosttyvendor/ghostty at c7f68a7 (upstream main, 2026-11-03)
Zig0.17.0 from flake.nix, with patches/zig/0000-* (Ghostty upstream) and 0001-win7-memory-and-futex.patch
Ghostty patchespatches/ghostty/0001-win7-memory-and-futex.patch
Test machineWindows 7 Ultimate SP1 (6.1.7601) x64, fully updated with the Universal CRT, running as a QEMU/KVM guest
Binariesvt_harness.exe with libghostty-vt linked in statically, built for x86_64-windows.win7-gnu and x86-windows.win7-gnu (ReleaseFast)

What we did

  1. The unpatched build fails. An unpatched build imports 4 functions that Windows 7 lacks: ntdll!RtlWaitOnAddress, RtlWakeAddressAll and RtlWakeAddressSingle (Windows 8+), and kernel32!DiscardVirtualMemory (Windows 8.1 Update+). Any missing import stops Windows from loading the DLL, so it can't load on Windows 7.
  2. Patched. The wait/wake calls are replaced with SRW locks plus a condition variable per waiter, in both Ghostty and Zig's standard library. DiscardVirtualMemory is replaced with VirtualAlloc(MEM_RESET), and with decommit then recommit where the memory must read back as zero.
  3. Import check. scripts/check-win7-imports.py reports OK for both DLLs and both harness exes.
  4. Linux regression check. With the patches applied, Ghostty's zig build test-lib-vt (Debug) gives 7,111 passed and 74 skipped. This doesn't exercise the Windows code paths.
  5. Windows 7 run. tests/run-win7.bat gives x64: 27 passed, 0 failed and x86: 27 passed, 0 failed. Each case runs a one-shot feed and a seeded chunked feed, and both must match.
  6. The test catches failures. Replacing one expected result with garbage made that case fail on both architectures, and the script exited nonzero.

Not verified

  • Unpatched exe on Windows 7. We ran it on the VM to confirm it fails to load. It returned no exit code, and the guest agent then stopped responding, so the result is inconclusive.
  • Wait/wake under contention, and memory reset under pressure. These are queued in the README roadmap under step 1, "Next up".

How to reproduce

nix develop -c bash tests/harness/build.sh       # builds the harness for native and Win7; runs the import check
nix develop -c bash tests/run-corpus.sh          # Linux goldens
nix develop -c bash scripts/package-win7-test.sh # build/voyager7-win7-test.zip
# Then on the Windows 7 machine: unzip it and run run-win7.bat.

2026-11-05: public-API scrollback corpus coverage

Ghostty remains pinned at c7f68a7. The C11 harness now emits VT-HARNESS 2, appending oldest-first scrollback rows with graphemes, widths, wraps and styles. One-shot and seeded chunked feeds must match the entire dump, including history. All 27 existing active-screen/metadata dumps are byte-identical to their prior goldens after removing the format bump and appended sections. Every golden was regenerated with the native ReleaseFast build; all are ASCII with LF endings.

Thirteen new cases (28–40) exercise styled history, partial scroll margins, page-granular pruning and disabled history, alternate-screen transitions, DECSC/DECRC and 1048/1049 with SGR and origin mode, ED 3, and resize/reflow. The styled-history and partial-region cases both retain the same 19 rows; partial-region scrolling adds no history. ED 3 and disabled history retain zero. The 6,000-line pruning case with a three-line limit retains 329 history rows (the public limit is explicitly page-granular). Resize from 40x12 to 23x8 leaves 73 history rows, including soft wraps. Restore cases recover origin mode, position and SGR before printing their marker.

API limits: inactive-screen and saved-cursor getters do not exist at this revision. Their dump records say unavailable public-api. Tracked references can retain individual inactive cells, but cannot enumerate arbitrary inactive screens. Snapshot APIs preserve state without structured getters for these fields. No internal pointers or private snapshot payloads are interpreted. Inactive-only/saved-only cases therefore remain coverage gaps; restore/return cases test observable effects. See the dump specification.

Linux output:

Wine used: no (native harness)
40 cases, 0 failures

Real Windows 7 Ultimate SP1 (6.1.7601), through the QEMU guest agent, output:

OK: no known post-Win7 imports
OK: no known post-Win7 imports
x64: 40 passed, 0 failed
x86: 38 passed, 2 failed
Details in results.txt

The import lines are from the build's checks of each executable before upload. The remaining lines are the VM batch runner's output (exit code 1). Full results.txt pulled from the VM records both x86 failures with exit=0: their harness runs succeeded, including chunked/one-shot equality, but history differs from the Linux x64 goldens:

CaseLinux x64 / Win7 x64 history rowsWin7 x86 history rows
27-stress1,1222,091
30-scrollback-limit329314

In both cases the entire active-screen and metadata prefix is byte-identical. After accounting for history-local row numbering, every row, wrap, grapheme, width and style in the common retained suffix also matches. The pruning case's first retained line is limit-5660 on x64 and limit-5675 on x86. These retention extent differences are consistent with the API's page-granular estimates; the public API does not expose page geometry to determine the underlying cause. The strict comparison deliberately keeps these failures visible rather than truncating history or accepting architecture-specific goldens. All other cases match the native goldens byte for byte on both Windows architectures.

Reproduction used tests/harness/build.sh, tests/run-corpus.sh, and scripts/package-win7-test.sh inside nix develop, then scripts/win7vm.py push-dir build/voyager7-win7-test C:\v7work\harness, exec C:\v7work\harness\run-win7.bat, and pull for the results and mismatches. The helper's quoted directory creation did not create missing directories; explicit exec mkdir commands created only the harness tree before retrying push-dir (86 files). No reboot or VM configuration changes were needed.