next_interupt = c + min;
}
+static void unusedInterrupt()
+{
+}
+
typedef void (irq_func)();
static irq_func * const irq_funcs[] = {
[PSXINT_SIO] = sioInterrupt,
[PSXINT_CDR] = cdrInterrupt,
- [PSXINT_CDREAD] = cdrReadInterrupt,
+ [PSXINT_CDREAD] = cdrPlaySeekReadInterrupt,
[PSXINT_GPUDMA] = gpuInterrupt,
[PSXINT_MDECOUTDMA] = mdec1Interrupt,
[PSXINT_SPUDMA] = spuInterrupt,
[PSXINT_GPUOTCDMA] = gpuotcInterrupt,
[PSXINT_CDRDMA] = cdrDmaInterrupt,
[PSXINT_CDRLID] = cdrLidSeekInterrupt,
- [PSXINT_CDRPLAY] = cdrPlayInterrupt,
+ [PSXINT_CDRPLAY_OLD] = unusedInterrupt,
[PSXINT_SPU_UPDATE] = spuUpdate,
[PSXINT_RCNT] = psxRcntUpdate,
};
void gen_interupt()
{
- evprintf(" +ge %08x, %u->%u\n", psxRegs.pc, psxRegs.cycle, next_interupt);
+ evprintf(" +ge %08x, %u->%u (%d)\n", psxRegs.pc, psxRegs.cycle,
+ next_interupt, next_interupt - psxRegs.cycle);
irq_test();
//psxBranchTest();
//if (psxRegs.cycle == 166172) breakme();
if (which_event >= 0 && event_cycles[which_event] != ev_cycles) {
- printf("bad ev_cycles #%d: %08x %08x\n", which_event, event_cycles[which_event], ev_cycles);
+ printf("bad ev_cycles #%d: %u %u / %u\n", which_event,
+ event_cycles[which_event], ev_cycles, psxRegs.cycle);
fatal = 1;
}