passing call timings
This commit is contained in:
@ -497,8 +497,10 @@ static void goto_addr(cpu_context *ctx, u16 addr, bool pushpc){
|
||||
if(ctx->cur_inst->reg_1 != RT_HL)
|
||||
emu_cycles(1);
|
||||
if(pushpc) {
|
||||
stack_push16(ctx->regs.pc);
|
||||
emu_cycles(2);
|
||||
stack_push((ctx->regs.pc >> 8) & 0xFF);
|
||||
emu_cycles(1);
|
||||
stack_push(ctx->regs.pc & 0xFF);
|
||||
emu_cycles(1);
|
||||
}
|
||||
ctx->regs.pc = addr;
|
||||
}
|
||||
|
Reference in New Issue
Block a user