Skip to content

[upstream #1062] xcl run: name a title's deliberate write of a tag to address 0 in the crash line - #89

Closed
ufoptg wants to merge 1 commit into
mainfrom
upstream-pr/1062
Closed

ufoptg wants to merge 1 commit into
mainfrom
upstream-pr/1062

Conversation

@ufoptg

@ufoptg ufoptg commented Nov 24, 2026

Copy link
Copy Markdown
Owner

Part of xcl-dev#505; the stop of xcl-dev#746 is the second of the two below.

Titles end themselves on purpose with mov dword ptr [0], imm32. XCL's line for the unhandled exception showed only write at address 0x0, which reads like a bug in XCL. The retail title of xcl-dev#505 does it twice:

Read from the title's code: the watchdog function reports the stall, then reaches the write on both of its paths; after the write it only returns (add rsp, 0x48; ret). The thread procedure that called it calls an optional hook, then writes 0 to address 0.

The crash line now ends with – the title's own deliberate crash: mov dword ptr [0], <tag> when the faulting instruction is that one. Nothing else changes.

What is in it

  • crates/xcl/src/eh.rs: deliberate_null_write (the instruction's tag) and its use in unhandled_filter for a write at address 0. Test: a_write_of_a_tag_to_address_0_is_named_a_deliberate_crash.

Tested

Regression run

main:

xcl-smoke v1
commit: 384f7f7f8c79fa4d4dee59336d650a4021af4c7e
gpu: NVIDIA GeForce RTX 4080 SUPER
title: GTA VI
seconds: 60
exit: 0x0
frames shown: 1322 (PresentX 1322)
presents per 2 s (last 3): 60 60 61
device removals: 0
crashes: 0
peak commit: 15231 MB

this PR:

xcl-smoke v1
commit: 0117b92df882ded62dda4060a4f0444499ee4c2d
gpu: NVIDIA GeForce RTX 4080 SUPER
title: GTA VI
seconds: 60
exit: 0x0
frames shown: 1389 (PresentX 1389)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14997 MB

Not tested

  • A crash line written by this change in a real run: neither 60 s run reaches the title's world load, where it ends itself; the test covers the instruction match.
  • AMD and Intel GPUs; Wine.
  • An earlier pair of runs had a higher peak commit (14.9 GB against 9.1 GB for main) while an offline pipeline builder held 75 GB of commit on the same machine; the pair above was made after it was stopped.

AI use

  • Claude Code with Claude Opus 5.5: read the title's code at the two addresses, wrote the change, the test and this description; the runs were made on my PC.

https://claude.ai/code/session_01SEW8zXNUmMq1tRUZpstWXS


Mirror of xcl-dev#1062 (auto-synced, do not edit).

… crash line

Titles end themselves on purpose with `mov dword ptr [0], imm32`. XCL's line
for the unhandled exception showed only "write at address 0x0", which reads
like a bug of XCL's own. The retail title of xcl-dev#505 does it twice: its GPU
watchdog ("GPU Loc Sig") at +0x23cf683 writes 0x4d8bd421, and when that
watchdog's function returns, its thread's exit path at +0x2215c35 writes 0
(the stop of xcl-dev#746). Read from the title's code: the watchdog's function
reports the stall, then reaches the write on both of its paths; after the
write it only returns; the thread procedure calls an optional hook and then
writes 0 to address 0.

The crash line now ends with "the title's own deliberate crash: mov dword
ptr [0], <tag>" when the faulting instruction is that one.

Assisted-by: Claude Code (Claude Opus 5.5)
@ufoptg

ufoptg commented Nov 25, 2026

Copy link
Copy Markdown
Owner Author

Upstream PR xcl-dev#1062 was closed or merged.

@ufoptg ufoptg closed this Nov 25, 2026
@ufoptg
ufoptg deleted the upstream-pr/1062 branch November 25, 2026 00:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants