cdrom: change pause timing again
[pcsx_rearmed.git] / libpcsxcore / r3000a.h
index fb5e1db..03aeee1 100644 (file)
@@ -25,9 +25,6 @@ extern "C" {
 #endif
 
 #include "psxcommon.h"
-#include "psxmem.h"
-#include "psxcounters.h"
-#include "psxbios.h"
 
 enum R3000Aexception {
        R3000E_Int = 0,      // Interrupt
@@ -166,25 +163,6 @@ typedef union {
        PAIR p[32];
 } psxCP2Ctrl;
 
-enum {
-       PSXINT_SIO = 0,
-       PSXINT_CDR,
-       PSXINT_CDREAD,
-       PSXINT_GPUDMA,
-       PSXINT_MDECOUTDMA,
-       PSXINT_SPUDMA,
-       PSXINT_GPUBUSY,
-       PSXINT_MDECINDMA,
-       PSXINT_GPUOTCDMA,
-       PSXINT_CDRDMA,
-       PSXINT_NEWDRC_CHECK,
-       PSXINT_RCNT,
-       PSXINT_CDRLID,
-       PSXINT_CDRPLAY_OLD,     /* unused */
-       PSXINT_SPU_UPDATE,
-       PSXINT_COUNT
-};
-
 enum R3000Abdt {
        // corresponds to bits 31,30 of Cause reg
        R3000A_BRANCH_TAKEN = 3,
@@ -224,6 +202,10 @@ typedef struct {
        u8  dloadSel;       /* interp. delay load state */
        u8  dloadReg[2];
        u32 dloadVal[2];
+       u32 biosBranchCheck;
+       u32 cpuInRecursion;
+       u32 gpuIdleAfter;
+       u32 reserved[1];
        // warning: changing anything in psxRegisters requires update of all
        // asm in libpcsxcore/new_dynarec/
 } psxRegisters;
@@ -231,24 +213,8 @@ typedef struct {
 extern psxRegisters psxRegs;
 
 /* new_dynarec stuff */
-extern u32 event_cycles[PSXINT_COUNT];
-extern u32 next_interupt;
-
 void new_dyna_freeze(void *f, int mode);
 
-#define new_dyna_set_event_abs(e, abs) { \
-       u32 abs_ = abs; \
-       s32 di_ = next_interupt - abs_; \
-       event_cycles[e] = abs_; \
-       if (di_ > 0) { \
-               /*printf("%u: next_interupt %u -> %u\n", psxRegs.cycle, next_interupt, abs_);*/ \
-               next_interupt = abs_; \
-       } \
-}
-
-#define new_dyna_set_event(e, c) \
-       new_dyna_set_event_abs(e, psxRegs.cycle + (c))
-
 int  psxInit();
 void psxReset();
 void psxShutdown();
@@ -257,6 +223,9 @@ void psxBranchTest();
 void psxExecuteBios();
 void psxJumpTest();
 
+void irq10Interrupt();
+void psxScheduleIrq10(int irq_count, int x_cycles, int y);
+
 #ifdef __cplusplus
 }
 #endif