From d28b54b1d1d161b3f3acc3299c43106a022451e6 Mon Sep 17 00:00:00 2001 From: notaz Date: Tue, 21 Dec 2010 15:46:24 +0200 Subject: core: update to newer interrupt code, seems to affect timings too pcsxr-svn commit: Author: weimingzhi Date: Sat Aug 7 23:52:44 2010 +0000 refactored the interrupt scheduling code a bit to make it a little more readable than using those "magic" numbers. --- libpcsxcore/new_dynarec/emu_if.c | 3 ++- libpcsxcore/new_dynarec/pcsxmem.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'libpcsxcore/new_dynarec') diff --git a/libpcsxcore/new_dynarec/emu_if.c b/libpcsxcore/new_dynarec/emu_if.c index 7f7d8f8..428f58b 100644 --- a/libpcsxcore/new_dynarec/emu_if.c +++ b/libpcsxcore/new_dynarec/emu_if.c @@ -12,6 +12,7 @@ #include "emu_if.h" #include "pcsxmem.h" #include "../psxhle.h" +#include "../r3000a.h" #define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0])) @@ -19,7 +20,7 @@ #define evprintf(...) char invalid_code[0x100000]; -u32 event_cycles[7]; +u32 event_cycles[PSXINT_COUNT]; static void schedule_timeslice(void) { diff --git a/libpcsxcore/new_dynarec/pcsxmem.c b/libpcsxcore/new_dynarec/pcsxmem.c index a526ac5..dc3ce69 100644 --- a/libpcsxcore/new_dynarec/pcsxmem.c +++ b/libpcsxcore/new_dynarec/pcsxmem.c @@ -134,7 +134,7 @@ static void io_write_imask16(u32 value) { psxHu16ref(0x1074) = value; if (psxHu16ref(0x1070) & value) - new_dyna_set_event(6, 1); + new_dyna_set_event(PSXINT_NEWDRC_CHECK, 1); } static void io_write_ireg32(u32 value) @@ -148,7 +148,7 @@ static void io_write_imask32(u32 value) { psxHu32ref(0x1074) = value; if (psxHu32ref(0x1070) & value) - new_dyna_set_event(6, 1); + new_dyna_set_event(PSXINT_NEWDRC_CHECK, 1); } static void io_write_dma_icr32(u32 value) -- cgit v1.2.3