Protoization.
[deliverable/binutils-gdb.git] / opcodes / mips-dis.c
index 11e322c2bba4fbaa8be1785a4f5c48b73d6ced20..fa33821f32c587fc832dd6627977c8cf20df08b3 100644 (file)
@@ -50,7 +50,7 @@ static int _print_insn_mips PARAMS ((bfd_vma, unsigned long int,
 
 \f
 /* FIXME: This should be shared with gdb somehow.  */
-#define REGISTER_NAMES         \
+#define STD_REGISTER_NAMES     \
     {  "zero", "at",   "v0",   "v1",   "a0",   "a1",   "a2",   "a3", \
        "t0",   "t1",   "t2",   "t3",   "t4",   "t5",   "t6",   "t7", \
        "s0",   "s1",   "s2",   "s3",   "s4",   "s5",   "s6",   "s7", \
@@ -64,13 +64,17 @@ static int _print_insn_mips PARAMS ((bfd_vma, unsigned long int,
        "epc",  "prid"\
     }
 
-static CONST char * CONST reg_names[] = REGISTER_NAMES;
+static CONST char * CONST std_reg_names[] = STD_REGISTER_NAMES;
 
 /* The mips16 register names.  */
 static const char * const mips16_reg_names[] =
 {
   "s0", "s1", "v0", "v1", "a0", "a1", "a2", "a3"
 };
+
+/* Scalar register names. set_mips_isa_type() decides which register name
+   table to use.  */
+static CONST char * CONST *reg_names = NULL;
 \f
 /* subroutine */
 static void
@@ -255,6 +259,9 @@ set_mips_isa_type (mach, isa, cputype)
   int target_processor = 0;
   int mips_isa = 0;
 
+  /* Use standard MIPS register names by default.  */
+  reg_names = std_reg_names;
+
   switch (mach)
     {
       case bfd_mach_mips3000:
This page took 0.023763 seconds and 4 git commands to generate.