]> git.sur5r.net Git - cc65/blobdiff - src/cc65/opcodes.h
Fixed the macro versions of several inline functions.
[cc65] / src / cc65 / opcodes.h
index ec798db22c217ce5e9ea05484c20eb3e60b66a89..fb9e3e53e32244b00e593cadb43e60b441c37a7a 100644 (file)
@@ -6,9 +6,9 @@
 /*                                                                           */
 /*                                                                           */
 /*                                                                           */
-/* (C) 2001      Ullrich von Bassewitz                                       */
-/*               Wacholderweg 14                                             */
-/*               D-70597 Stuttgart                                           */
+/* (C) 2001-2004 Ullrich von Bassewitz                                       */
+/*               Römerstraße 52                                              */
+/*               D-70794 Filderstadt                                         */
 /* EMail:        uz@cc65.org                                                 */
 /*                                                                           */
 /*                                                                           */
 
 
 
-/* Definitions for the possible opcodes */
+/* 65XX opcodes */
 typedef enum {
-
-    /* 65XX opcodes */
     OP65_ADC,
     OP65_AND,
     OP65_ASL,
@@ -118,6 +116,7 @@ typedef enum {
     OP65_STA,
     OP65_STX,
     OP65_STY,
+    OP65_STZ,
     OP65_TAX,
     OP65_TAY,
     OP65_TRB,
@@ -128,24 +127,11 @@ typedef enum {
     OP65_TYA,
 
     /* Number of opcodes available */
-    OPCODE_COUNT,
-
-    /* Several other opcode information constants */
-    OP65_FIRST = OP65_ADC,
-    OP65_LAST  = OP65_TYA,
-    OP65_COUNT = OP65_LAST - OP65_FIRST + 1
+    OP65_COUNT
 } opc_t;
 
-/* Addressing modes */
+/* 65XX addressing modes */
 typedef enum {
-
-    /* Addressing modes of the virtual stack machine */
-    AM_IMP,
-    AM_IMM,
-    AM_STACK,
-    AM_ABS,
-
-    /* 65XX addressing modes */
     AM65_IMP,                  /* implicit */
     AM65_ACC,                  /* accumulator */
     AM65_IMM,                  /* immidiate */
@@ -188,6 +174,7 @@ typedef enum {
 #define OF_REG_INCDEC   0x0400U /* A register increment or decrement */
 #define OF_SETF         0x0800U /* Insn will set all load flags (not carry) */
 #define OF_CMP          0x1000U /* A compare A/X/Y instruction */
+#define OF_NOIMP        0x2000U /* Implicit addressing mode is actually A */
 
 /* Combined infos */
 #define OF_BRA         (OF_UBRA | OF_CBRA)     /* Operation is a jump/branch */
@@ -204,7 +191,7 @@ typedef struct {
 } OPCDesc;
 
 /* Opcode description table */
-extern const OPCDesc OPCTable[OPCODE_COUNT];
+extern const OPCDesc OPCTable[OP65_COUNT];