gcc.c-torture/compile/20001226-1.c started failing for MIPS16 after
the microMIPS patch.  This was because the patch added a new check of
"extended_mips16" at the top of the "length" attribute, before the
check for branch lengths, and because "extended_mips16" was still set
to "yes" for branch instructions.  However, it was really my fault
for not removing the branch check from extended_mips16 when adding
the long branch support.

Fixed as follows.  Tested on mipsisa32-sde-elf and applied.

Richard


gcc/
        * config/mips/mips.md (extended_mips16): Remove branch case.
        (length): Remove duplicated extended_mips16 test.

Index: gcc/config/mips/mips.md
===================================================================
--- gcc/config/mips/mips.md     2013-05-19 10:57:13.399153082 +0100
+++ gcc/config/mips/mips.md     2013-05-19 10:57:24.039233504 +0100
@@ -407,7 +407,6 @@ (define_attr "cnv_mode" "unknown,I2S,I2D
 ;; Is this an extended instruction in mips16 mode?
 (define_attr "extended_mips16" "no,yes"
   (if_then_else (ior (eq_attr "move_type" "sll0")
-                    (eq_attr "type" "branch")
                     (eq_attr "jal" "direct"))
                (const_string "yes")
                (const_string "no")))
@@ -586,10 +585,6 @@ (define_attr "length" ""
                 (const_int 32)
                 ] (const_int 48))
 
-         (and (eq_attr "extended_mips16" "yes")
-              (match_test "TARGET_MIPS16"))
-         (const_int 8)
-
          ;; "Ghost" instructions occupy no space.
          (eq_attr "type" "ghost")
          (const_int 0)

Reply via email to