* ppc.h (PPC_OPERAND_NEXT): Define.
authorIan Lance Taylor <ian@airs.com>
Sat, 5 Feb 1994 04:38:05 +0000 (04:38 +0000)
committerIan Lance Taylor <ian@airs.com>
Sat, 5 Feb 1994 04:38:05 +0000 (04:38 +0000)
(PPC_OPERAND_NEGATIVE): Change value to make room for above.
(struct powerpc_macro): Define.
(powerpc_macros, powerpc_num_macros): Declare.

include/opcode/ChangeLog
include/opcode/ppc.h

index 93a6d98c0030a2b750cd5d82b9b0aafd746a0fad..1dd2bb2805f1db0a0669bb01296f919dd87d35e7 100644 (file)
@@ -1,3 +1,10 @@
+Fri Feb  4 23:36:52 1994  Ian Lance Taylor  (ian@tweedledumb.cygnus.com)
+
+       * ppc.h (PPC_OPERAND_NEXT): Define.
+       (PPC_OPERAND_NEGATIVE): Change value to make room for above.
+       (struct powerpc_macro): Define.
+       (powerpc_macros, powerpc_num_macros): Declare.
+
 Fri Jan 21 19:13:50 1994  Ian Lance Taylor  (ian@tweedledumb.cygnus.com)
 
        * ppc.h: New file.  Header file for PowerPC opcode table.
index 0e87796ba2975f980ad93a430c0d1f1296a898ed..9be913d6f9652f50713fa7fcfd23c594ee4f038e 100644 (file)
@@ -186,11 +186,45 @@ extern const struct powerpc_operand powerpc_operands[];
    print this operand out only if it is not zero.  */
 #define PPC_OPERAND_OPTIONAL (0400)
 
+/* This flag is only used with PPC_OPERAND_OPTIONAL.  If this operand
+   is omitted, then for the next operand use this operand value plus
+   1, ignoring the next operand field for the opcode.  This wretched
+   hack is needed because the Power rotate instructions can take
+   either 4 or 5 operands.  The disassembler should print this operand
+   out regardless of the PPC_OPERAND_OPTIONAL field.  */
+#define PPC_OPERAND_NEXT (01000)
+
 /* This operand should be regarded as a negative number for the
    purposes of overflow checking (i.e., the normal most negative
    number is disallowed and one more than the normal most positive
    number is allowed).  This flag will only be set for a signed
    operand.  */
-#define PPC_OPERAND_NEGATIVE (01000)
+#define PPC_OPERAND_NEGATIVE (02000)
+\f
+/* The POWER and PowerPC assemblers use a few macros.  We keep them
+   with the operands table for simplicity.  The macro table is an
+   array of struct powerpc_macro.  */
+
+struct powerpc_macro
+{
+  /* The macro name.  */
+  const char *name;
+
+  /* The number of operands the macro takes.  */
+  unsigned int operands;
+
+  /* One bit flags for the opcode.  These are used to indicate which
+     specific processors support the instructions.  The values are the
+     same as those for the struct powerpc_opcode flags field.  */
+  unsigned long flags;
+
+  /* A format string to turn the macro into a normal instruction.
+     Each %N in the string is replaced with operand number N (zero
+     based).  */
+  const char *format;
+};
+
+extern const struct powerpc_macro powerpc_macros[];
+extern const int powerpc_num_macros;
 
 #endif /* PPC_H */
This page took 0.025903 seconds and 4 git commands to generate.