mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 00:11:24 +12:00
Debugger fixups (#9226)
Fix logic error in callstacks handling code, always set first to false after first iteration. Add explicit check for zero return addresses. Current code validity checks may not check for it properly when it sits on interrupt handler entry point (which may contain valid code). Do not allow 0x3FFF0 to be a back chain address because it needs space for LR save area, only 0x3FFE0 and below satisfy this criteria.
This commit is contained in:
parent
5265eb81e0
commit
bacfa9be19
3 changed files with 6 additions and 6 deletions
|
@ -584,7 +584,7 @@ std::vector<std::pair<u32, u32>> ppu_thread::dump_callstack_list() const
|
|||
for (
|
||||
u64 sp = r1;
|
||||
sp % 0x10 == 0u && sp >= stack_min && sp <= stack_max - ppu_stack_start_offset;
|
||||
sp = *vm::get_super_ptr<u64>(static_cast<u32>(sp))
|
||||
sp = *vm::get_super_ptr<u64>(static_cast<u32>(sp)), first = false
|
||||
)
|
||||
{
|
||||
u64 addr = *vm::get_super_ptr<u64>(static_cast<u32>(sp + 16));
|
||||
|
@ -602,7 +602,7 @@ std::vector<std::pair<u32, u32>> ppu_thread::dump_callstack_list() const
|
|||
|
||||
if (is_invalid(addr))
|
||||
{
|
||||
if (std::exchange(first, false))
|
||||
if (first)
|
||||
{
|
||||
// Function hasn't saved LR, could be because it's a leaf function
|
||||
// Use LR directly instead
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue