X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=pcsx_rearmed.git;a=blobdiff_plain;f=libpcsxcore%2Fnew_dynarec%2Fpatches%2Ftrace_drc_chk;fp=libpcsxcore%2Fnew_dynarec%2Fpatches%2Ftrace_drc_chk;h=12eeb8ae2be65d0c14b6ae36242241659f895348;hp=414c22156345a64fe9021d0a4e3ed44c1bf3bef4;hb=a5cd72d0e598f037fd9d9f23948af5b2fb06e2eb;hpb=9165d434d935746da54484381ebbee754e899680 diff --git a/libpcsxcore/new_dynarec/patches/trace_drc_chk b/libpcsxcore/new_dynarec/patches/trace_drc_chk index 414c2215..12eeb8ae 100644 --- a/libpcsxcore/new_dynarec/patches/trace_drc_chk +++ b/libpcsxcore/new_dynarec/patches/trace_drc_chk @@ -1,8 +1,8 @@ diff --git a/libpcsxcore/new_dynarec/new_dynarec.c b/libpcsxcore/new_dynarec/new_dynarec.c -index b160a4a..0d91999 100644 +index 2821d466..b3c7ea2f 100644 --- a/libpcsxcore/new_dynarec/new_dynarec.c +++ b/libpcsxcore/new_dynarec/new_dynarec.c -@@ -285,7 +285,7 @@ static struct decoded_insn +@@ -311,7 +311,7 @@ static struct decoded_insn int new_dynarec_hacks_old; int new_dynarec_did_compile; @@ -11,7 +11,7 @@ index b160a4a..0d91999 100644 extern int cycle_count; // ... until end of the timeslice, counts -N -> 0 extern int last_count; // last absolute target, often = next_interupt -@@ -532,6 +532,7 @@ static int cycle_multiplier_active; +@@ -593,6 +593,7 @@ static int cycle_multiplier_active; static int CLOCK_ADJUST(int x) { @@ -19,7 +19,7 @@ index b160a4a..0d91999 100644 int m = cycle_multiplier_active; int s = (x >> 31) | 1; return (x * m + s * 50) / 100; -@@ -662,6 +663,9 @@ static void *try_restore_block(u_int vaddr, u_int start_page, u_int end_page) +@@ -745,6 +746,9 @@ static void *try_restore_block(u_int vaddr, u_int start_page, u_int end_page) // This is called from the recompiled JR/JALR instructions static void noinline *get_addr(u_int vaddr, int can_compile) { @@ -29,7 +29,7 @@ index b160a4a..0d91999 100644 u_int start_page = get_page_prev(vaddr); u_int i, page, end_page = get_page(vaddr); void *found_clean = NULL; -@@ -7046,7 +7050,7 @@ static noinline void pass2_unneeded_regs(int istart,int iend,int r) +@@ -7143,7 +7147,7 @@ static noinline void pass2_unneeded_regs(int istart,int iend,int r) // R0 is always unneeded u|=1; // Save it @@ -38,7 +38,7 @@ index b160a4a..0d91999 100644 gte_unneeded[i]=gte_u; /* printf("ur (%d,%d) %x: ",istart,iend,start+i*4); -@@ -8236,6 +8240,7 @@ static noinline void pass5a_preallocate1(void) +@@ -8292,6 +8296,7 @@ static noinline void pass5a_preallocate1(void) static noinline void pass5b_preallocate2(void) { int i, hr; @@ -46,7 +46,7 @@ index b160a4a..0d91999 100644 for(i=0;isubCycleStep >= 0x10000); + regs->subCycle += regs->subCycleStep; +- regs->cycle += regs->subCycle >> 16; ++ regs->cycle += 2; //regs->subCycle >> 16; + regs->subCycle &= 0xffff; + } + +@@ -1341,8 +1341,14 @@ static void intShutdown() { + + // single step (may do several ops in case of a branch or load delay) + void execI(psxRegisters *regs) { ++ extern int last_count; ++ void do_insn_cmp(void); ++ printf("execI %08x c %u, ni %u\n", regs->pc, regs->cycle, next_interupt); ++ last_count = 0; + do { + execIbp(psxMemRLUT, regs); ++ if (regs->dloadReg[0] || regs->dloadReg[1]) ++ do_insn_cmp(); + } while (regs->dloadReg[0] || regs->dloadReg[1]); + } +