ppu/sys_interrupt: add stack_reset command to fix sys_interrupt stack overflowing

This commit is contained in:
Jake 2018-03-05 20:36:33 -06:00 committed by Ivan
parent 3a9428a88e
commit 7bbadfd08b
3 changed files with 7 additions and 0 deletions

View file

@ -575,6 +575,11 @@ void ppu_thread::cpu_task()
cmd_pop(), lv2_obj::sleep(*this);
break;
}
case ppu_cmd::reset_stack:
{
cmd_pop(), gpr[1] = ::align(stack_addr + stack_size, 0x200) - 0x200;
break;
}
default:
{
fmt::throw_exception("Unknown ppu_cmd(0x%x)" HERE, (u32)type);