Merge pull request #5962 from nikowolf123/feat/libc-crash-register-text

feat(libc): print the text that registers point at in Windows crash reports
This commit is contained in:
Adrià authored and GitHub committed 2026-10-17 06:51:43 +02:00
commit 7c3bfa8632
6 files changed
+191

No files matched your search

+2
View File
@@ -212,6 +212,8 @@ Limits are listed in the [libc](../dev/debt/libc.md) and [relinker](../dev/debt/
### Windows crash diagnostics
When a register points at readable memory that starts with at least four printable ASCII characters, either as UTF-16LE or as single bytes, the crash report prints that text after the register memory dump, as `[r13] u"..."` for UTF-16LE or `[rdi] "..."` for single bytes. The text ends at a NUL, at the first character that is not printable ASCII, a tab, a line feed or a carriage return, after 512 characters or at the end of readable memory. Tabs, line breaks, quotes and backslashes are escaped, and `...` after the closing quote means that no NUL ended the text within those limits.
Set `APS5_CRASH_INDIRECT_MEMORY=1` before launching the executable to include up to 64 bytes from each pointer found in the register memory dump. The report labels each block with its register, pointer offset and target address. Inaccessible, incomplete and executable targets are skipped. This additional dump is disabled when the variable is unset or empty.
### GPU submission rings and stall dumps