input: make it more modular
[picodrive.git] / cpu / Cyclone / OpBranch.cpp
index 061fe01..63569da 100644 (file)
@@ -5,10 +5,14 @@
 static void CheckPc(void)\r
 {\r
 #if USE_CHECKPC_CALLBACK\r
+ #ifdef MEMHANDLERS_DIRECT_PREFIX\r
+  ot("  bl %scheckpc ;@ Call checkpc()\n", MEMHANDLERS_DIRECT_PREFIX);\r
+ #else\r
   ot(";@ Check Memory Base+pc\n");\r
   ot("  mov lr,pc\n");\r
   ot("  ldr pc,[r7,#0x64] ;@ Call checkpc()\n");\r
   ot("\n");\r
+ #endif\r
 #endif\r
 }\r
 \r
@@ -500,7 +504,7 @@ int OpBranch(int op)
   OpEnd(size?0x10:0);\r
 \r
   // since all "DontBranch" code is same for every size, output only once\r
-  if (cc>=2&&(op&0xff00)==0x6200)\r
+  if (cc>=2&&(op&0xff00)==0x6700)\r
   {\r
     ot("BccDontBranch%i%s\n", 8<<size, ms?"":":");\r
     if (size) ot("  add r4,r4,#%d\n",1<<size);\r