adjustments for MAME
[picodrive.git] / cpu / Cyclone / config.h
index bcea68d..ded00b1 100644 (file)
  * Enable this option if you are going to use Cyclone to emulate Genesis /\r
  * Mega Drive system. As VDP chip in these systems had control of the bus,\r
  * several instructions were acting differently, for example TAS did'n have\r
- * the write-back phase. That will be emulated, if this option is enebled.\r
+ * the write-back phase. That will be emulated, if this option is enabled.\r
  * This option also alters timing slightly.\r
  */\r
-#define CYCLONE_FOR_GENESIS          1\r
+#define CYCLONE_FOR_GENESIS       1\r
 \r
 /*\r
  * This option compresses Cyclone's jumptable. Because of this the executable\r
  */\r
 #define COMPRESS_JUMPTABLE        1\r
 \r
+/*\r
+ * Address mask for memory hadlers. The bits set will be masked out of address\r
+ * parameter, which is passed to r/w memory handlers.\r
+ * Using 0xff000000 means that only 24 least significant bits should be used.\r
+ * Set to 0 if you want to mask unused address bits in the memory handlers yourself.\r
+ */\r
+#define MEMHANDLERS_ADDR_MASK     0xff000000\r
+\r
 /*\r
  * Cyclone keeps the 4 least significant bits of SR, PC+membase and it's cycle\r
  * count in ARM registers instead of the context for performance reasons. If you for\r
  * any reason need to access them in your memory handlers, enable the options below,\r
  * otherwise disable them to improve performance.\r
- * Warning: the PC value will not point to start of instruction (it will be middle or\r
- * end), also updating PC is dangerous, as Cyclone may internally increment the PC\r
- * before fetching the next instruction and continue executing at wrong location.\r
+ * PC value will point to start of instruction currently executed.\r
+ * Warning: updating PC in memhandlers is dangerous, as Cyclone may internally\r
+ * increment the PC before fetching the next instruction and continue executing\r
+ * at wrong location.\r
  */\r
 #define MEMHANDLERS_NEED_PC       0\r
 #define MEMHANDLERS_NEED_FLAGS    0\r
@@ -70,7 +79,7 @@
  * If enabled, UnrecognizedCallback is called if an invalid opcode is\r
  * encountered. All context members are valid and can be changed. The handler\r
  * should return zero if you want Cyclone to gererate "Illegal Instruction"\r
- * exception after this, or nonzero if not. In the later case you shuold change\r
+ * exception after this, or nonzero if not. In the later case you should change\r
  * the PC by yourself, or else Cyclone will keep executing that opcode all over\r
  * again.\r
  * If disabled, "Illegal Instruction" exception is generated and execution is\r