tests: serve faulting SRT walker test loads on macOS too #1882
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
GPU
GUI
help wanted
question
Shaders
Video
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/KytyPS5--KytyPS5!1882
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1882/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Nawid3333 on GitHub · 2026-10-24 18:26 UTC · original
Nawid3333:fix/macos-srt-test-faults→main· +21 −2 · 1 files · 1 commits · closed without mergingSince
d7856753("shader: walk every resource plan with the x86 SRT walker"), the macOS CI job failsscalar_provenance,resource_materializationandresource_trackingwith a SegFault, for example onmain8291cfeb(https://github.com/KytyPS5/KytyPS5/actions/runs/40076044366). A fork CI run on each commit after6aaa5332puts it there:bdf48dcfpasses all 15 macOS ctest programs (https://github.com/Nawid3333/KytyPS5/actions/runs/40114324468), andd7856753fails these three (https://github.com/Nawid3333/KytyPS5/actions/runs/40114326653).FakeGuestMemory(tests/SrtWalkerTestMemory.h) completes a faulting walker load with the test reader's value, but it installed its fault handler only on Linux and Windows. On macOS nothing handled the fault, so a walker load from a fake guest address crashed the test.This adds the macOS branch: the same handler on the Darwin thread state (
uc_mcontext->__ss), for SIGSEGV and SIGBUS, ashostException.cppdoes. Linux and Windows are unchanged.Fork CI on this commit, on top of
8291cfeb: https://github.com/Nawid3333/KytyPS5/actions/runs/40116993847. macOS passes all 15 ctest programs, including the three above; Windows and Linux pass.AI use: Claude Code found the commit with the fork CI runs and wrote this change with me; I reviewed the diff and the CI results.
🤖 Generated with Claude Code
@coderabbitai[bot] on GitHub · 2026-10-24 18:31 UTC · original
No actionable comments were generated in the recent review.
3bb010fe-ae64-468f-9c66-d4958a7607ccReviewing files that changed from the base of the PR and between
906d25568fanda668255525.tests/SrtWalkerTestMemory.hIncluded review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
Walkthrough
The test memory helper now installs and restores signal handlers on macOS as well as Linux. On macOS, it handles SIGBUS in addition to SIGSEGV. Its new handler checks the faulting load length, writes the reader result or zero to the saved RAX register, and advances RIP. The Windows exception-handler path is unchanged.
Suggested reviewers:
nmzikPriority:
Normal
Change: Other
Merge Risk:
Minimal · up to
a6682No merge-blocking risk is established by this change.
Pre-merge checks:
4 ·
1
d7856753), the missing macOS handler in FakeGuestMemory, and the fix th…Full details: Title check
Explanation
The title names the main change: a macOS fault handler in the test fake guest memory so faulting SRT walker loads are served on macOS. It matches the raw summary and the PR objectives, and it states the change specifically.
Full details: Description check
Explanation
The description explains the cause (macOS CI failures of scalar_provenance, resource_materialization and resource_tracking after
d7856753), the missing macOS handler in FakeGuestMemory, and the fix that adds the Darwin thread-state handler for SIGSEGV and SIGBUS. It is directly related to the changeset.Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
Comment
@coderabbitai helpto get the list of available commands.@Nawid3333 on GitHub · 2026-10-27 16:22 UTC · original
Closing:
mainhas this since770438ce(#1922, "ci: fix the Linux build and the macOS SRT walker test crashes"), which adds the same macOS handler for SIGSEGV and SIGBUS on the Darwin thread state. macOS CI passes onmain0685bffb(https://github.com/KytyPS5/KytyPS5/actions/runs/40482692093).Pull request closed