Host signal frames are pushed onto the guest stack, so GuestRedZonePatcher protects functions that keep live data in the 128-byte red zone. It only recognized RSP-relative accesses. Clang spills just as often through the frame pointer: after 'push rbp; mov rbp, rsp' and N callee-saved pushes, RSP sits at RBP-N and every [rbp-d] with d > N is below RSP. A fault taken there (lazy commit, write tracking) overwrote those slots, which showed up as garbage pointers on random threads in Poppy Playtime's level load. Derive RBP-to-RSP from the standard prologue (leading pushes and the first 'sub rsp, imm') and treat [rbp-d] in (delta, delta + 128] as red-zone use. An under-estimated delta only widens the guarded window. In Poppy's eboot this protects 787 functions instead of 485. |
||
|---|---|---|
| .. | ||
| GuestRedZoneEnclosingSpanTests.cs | ||
| GuestRedZonePatcherTests.cs | ||
| RosettaVectorStorePatchTests.cs | ||
| SelfLoaderTests.cs | ||
| TlsInitializationTests.cs | ||