aboutsummaryrefslogtreecommitdiff
path: root/opcodes/mips-opc.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1997-03-27 19:25:01 +0000
committerIan Lance Taylor <ian@airs.com>1997-03-27 19:25:01 +0000
commita21e1e96beeb987a8193232aa9f5f1652a23d372 (patch)
tree65729a0f05196749ceca62f8ec92d853cde71bc6 /opcodes/mips-opc.c
parent9b8b7e970e3a7a1d5794d38f29a14beb84b75163 (diff)
downloadgdb-a21e1e96beeb987a8193232aa9f5f1652a23d372.zip
gdb-a21e1e96beeb987a8193232aa9f5f1652a23d372.tar.gz
gdb-a21e1e96beeb987a8193232aa9f5f1652a23d372.tar.bz2
* mips-opc.c: Add cast when setting mips_opcodes.
Diffstat (limited to 'opcodes/mips-opc.c')
-rw-r--r--opcodes/mips-opc.c20
1 files changed, 13 insertions, 7 deletions
diff --git a/opcodes/mips-opc.c b/opcodes/mips-opc.c
index 26eab12..6c43125 100644
--- a/opcodes/mips-opc.c
+++ b/opcodes/mips-opc.c
@@ -1,5 +1,5 @@
/* mips.h. Mips opcode list for GDB, the GNU debugger.
- Copyright 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997 Free Software Foundation, Inc.
Contributed by Ralph Campbell and OSF
Commented and modified by Ian Lance Taylor, Cygnus Support
@@ -310,6 +310,9 @@ const struct mips_opcode mips_builtin_opcodes[] = {
{"daddiu", "t,r,j", 0x64000000, 0xfc000000, WR_t|RD_s|I3 },
{"daddu", "d,v,t", 0x0000002d, 0xfc0007ff, WR_d|RD_s|RD_t|I3},
{"daddu", "t,r,I", 3, (int) M_DADDU_I, INSN_MACRO },
+/* dctr and dctw are used on the r5000. */
+{"dctr", "o(b)", 0xbc050000, 0xfc1f0000, RD_b|I3 },
+{"dctw", "o(b)", 0xbc090000, 0xfc1f0000, RD_b|I3 },
/* For ddiv, see the comments about div. */
{"ddiv", "z,s,t", 0x0000001e, 0xfc00ffff, RD_s|RD_t|WR_HI|WR_LO|I3 },
{"ddiv", "d,v,t", 3, (int) M_DDIV_3, INSN_MACRO },
@@ -960,10 +963,13 @@ const struct mips_opcode mips_builtin_opcodes[] = {
{"cop3", "C", 0, (int) M_COP3, INSN_MACRO },
};
-/* const removed from definition to allow for dynamic extensions to the
- * built-in instruction set. */
-const int bfd_mips_num_builtin_opcodes =
- ((sizeof mips_builtin_opcodes) / (sizeof (mips_builtin_opcodes[0])));
+#define MIPS_NUM_OPCODES \
+ ((sizeof mips_builtin_opcodes) / (sizeof (mips_builtin_opcodes[0])))
+const int bfd_mips_num_builtin_opcodes = MIPS_NUM_OPCODES;
-struct mips_opcode *mips_opcodes = 0;
-int bfd_mips_num_opcodes = 0;
+/* const removed from the following to allow for dynamic extensions to the
+ * built-in instruction set. */
+struct mips_opcode *mips_opcodes =
+ (struct mips_opcode *) mips_builtin_opcodes;
+int bfd_mips_num_opcodes = MIPS_NUM_OPCODES;
+#undef MIPS_NUM_OPCODES