drc: re-add bt part that was removed with pass7
authornotaz <notasas@gmail.com>
Tue, 14 Jun 2011 16:21:55 +0000 (19:21 +0300)
committernotaz <notasas@gmail.com>
Tue, 14 Jun 2011 16:21:55 +0000 (19:21 +0300)
..as noticed by Ari64.

libpcsxcore/new_dynarec/new_dynarec.c

index db766b3..712a034 100644 (file)
@@ -10537,6 +10537,19 @@ int new_recompile_block(int addr)
     }
     //requires_32bit[i]=is32[i]&~unneeded_reg_upper[i]; // DEBUG
   }
     }
     //requires_32bit[i]=is32[i]&~unneeded_reg_upper[i]; // DEBUG
   }
+#else
+  for (i=slen-1;i>=0;i--)
+  {
+    if(itype[i]==CJUMP||itype[i]==SJUMP||itype[i]==FJUMP)
+    {
+      // Conditional branch
+      if((source[i]>>16)!=0x1000&&i<slen-2) {
+        // Mark this address as a branch target since it may be called
+        // upon return from interrupt
+        bt[i+2]=1;
+      }
+    }
+  }
 #endif
 
   if(itype[slen-1]==SPAN) {
 #endif
 
   if(itype[slen-1]==SPAN) {