2013-09-12 Chao-ying Fu <Chao-ying.Fu@imgtec.com>
authorChao-ying Fu <fu@mips.com>
Thu, 12 Sep 2013 21:41:09 +0000 (21:41 +0000)
committerChao-ying Fu <fu@mips.com>
Thu, 12 Sep 2013 21:41:09 +0000 (21:41 +0000)
* config/tc-mips.c (match_insn): Set error when $31 is used for
bltzal* and bgezal*.

gas/ChangeLog
gas/config/tc-mips.c

index 89c9cc9b556e2af16a259138ed0ec961239dfe34..8434721a206a79b5803efa79fae2b24861fae98f 100644 (file)
@@ -1,3 +1,8 @@
+2013-09-12  Chao-ying Fu  <Chao-ying.Fu@imgtec.com>
+
+       * config/tc-mips.c (match_insn): Set error when $31 is used for
+       bltzal* and bgezal*.
+
 2013-09-04  Tristan Gingold  <gingold@adacore.com>
 
        * config/tc-ppc.c (md_apply_fix): Handle defined after use toc
index ca95922ef3c3a977fb1f45ac8187bb0f5c6be1b4..ff1c610d605d0aef54f876a8cabcc6677c8f5a4d 100644 (file)
@@ -7091,6 +7091,10 @@ match_insn (struct mips_cl_insn *insn, const struct mips_opcode *opcode,
                set_insn_error
                  (0, _("a destination register must be supplied"));
            }
+         else if (arg.last_regno == 31
+                  && (strncmp (insn->insn_mo->name, "bltzal", 6) == 0
+                      || strncmp (insn->insn_mo->name, "bgezal", 6) == 0))
+           set_insn_error (0, _("the source register must not be $31"));
          check_completed_insn (&arg);
          return TRUE;
        }
This page took 0.043828 seconds and 4 git commands to generate.