mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-08 07:51:28 +12:00
PPU LLVM improved
This commit is contained in:
parent
2fd58dc7e8
commit
b1f1a5885b
4 changed files with 31 additions and 24 deletions
|
@ -358,25 +358,22 @@ std::string ppu_thread::dump() const
|
|||
for (uint i = 0; i < 32; ++i) ret += fmt::format("FPR[%d] = %.6G\n", i, fpr[i]);
|
||||
for (uint i = 0; i < 32; ++i) ret += fmt::format("VR[%d] = %s [x: %g y: %g z: %g w: %g]\n", i, vr[i], vr[i]._f[3], vr[i]._f[2], vr[i]._f[1], vr[i]._f[0]);
|
||||
|
||||
if (g_cfg_ppu_decoder.get() != ppu_decoder_type::llvm)
|
||||
{
|
||||
ret += fmt::format("CR = 0x%08x\n", cr_pack());
|
||||
ret += fmt::format("LR = 0x%llx\n", lr);
|
||||
ret += fmt::format("CTR = 0x%llx\n", ctr);
|
||||
ret += fmt::format("VRSAVE = 0x%08x\n", vrsave);
|
||||
ret += fmt::format("XER = [CA=%u | OV=%u | SO=%u | CNT=%u]\n", xer.ca, xer.ov, xer.so, xer.cnt);
|
||||
ret += fmt::format("VSCR = [SAT=%u | NJ=%u]\n", sat, nj);
|
||||
ret += fmt::format("FPSCR = [FL=%u | FG=%u | FE=%u | FU=%u]\n", fpscr.fl, fpscr.fg, fpscr.fe, fpscr.fu);
|
||||
ret += fmt::format("CR = 0x%08x\n", cr_pack());
|
||||
ret += fmt::format("LR = 0x%llx\n", lr);
|
||||
ret += fmt::format("CTR = 0x%llx\n", ctr);
|
||||
ret += fmt::format("VRSAVE = 0x%08x\n", vrsave);
|
||||
ret += fmt::format("XER = [CA=%u | OV=%u | SO=%u | CNT=%u]\n", xer.ca, xer.ov, xer.so, xer.cnt);
|
||||
ret += fmt::format("VSCR = [SAT=%u | NJ=%u]\n", sat, nj);
|
||||
ret += fmt::format("FPSCR = [FL=%u | FG=%u | FE=%u | FU=%u]\n", fpscr.fl, fpscr.fg, fpscr.fe, fpscr.fu);
|
||||
|
||||
// TODO: support foreign stack
|
||||
ret += "\nCall stack:\n=========\n";
|
||||
ret += fmt::format("0x%08x (0x0) called\n", cia);
|
||||
const u32 stack_max = ::align(stack_addr + stack_size, 0x200) - 0x200;
|
||||
for (u64 sp = vm::read64(static_cast<u32>(gpr[1])); sp >= stack_addr && sp < stack_max; sp = vm::read64(static_cast<u32>(sp)))
|
||||
{
|
||||
// TODO: print also function addresses
|
||||
ret += fmt::format("> from 0x%08llx (0x0)\n", vm::read64(static_cast<u32>(sp + 16)));
|
||||
}
|
||||
// TODO: support foreign stack
|
||||
ret += "\nCall stack:\n=========\n";
|
||||
ret += fmt::format("0x%08x (0x0) called\n", g_cfg_ppu_decoder.get() == ppu_decoder_type::llvm ? 0 : cia);
|
||||
const u32 stack_max = ::align(stack_addr + stack_size, 0x200) - 0x200;
|
||||
for (u64 sp = vm::read64(static_cast<u32>(gpr[1])); sp >= stack_addr && sp < stack_max; sp = vm::read64(static_cast<u32>(sp)))
|
||||
{
|
||||
// TODO: print also function addresses
|
||||
ret += fmt::format("> from 0x%08llx (0x0)\n", vm::read64(static_cast<u32>(sp + 16)));
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue