]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
MIPS: Remove -m(no-)lra option
authorYunQiang Su <syq@gcc.gnu.org>
Wed, 15 May 2024 18:30:50 +0000 (02:30 +0800)
committerYunQiang Su <syq@debian.org>
Mon, 20 May 2024 07:44:39 +0000 (15:44 +0800)
PR target/113955
The `-mlra` option was introduced in 2014 for MIPS, and was set to
default since then.  It's time for us to drop no-lra support by
dropping -m(no-)lra options.

gcc:
* config/mips/mips.cc(mips_option_override):
Drop mips_lra_flag variable;
(mips_lra_p): Removed.
(TARGET_LRA_P): Remove definition here to use the default one.
* config/mips/mips.md(*mul_acc_si, *mul_acc_si_r3900, *mul_sub_si):
Drop mips_lra_flag variable.
* config/mips/mips.opt(-mlra): Removed.
* config/mips/mips.opt.urls(mlra): Removed.

gcc/config/mips/mips.cc
gcc/config/mips/mips.md
gcc/config/mips/mips.opt
gcc/config/mips/mips.opt.urls

index ce764a5cb3591b08ef1afb70b2547d54e7df3839..b63d40a357b7c1f294e2c82062f0ef75fc307ba8 100644 (file)
@@ -20391,8 +20391,6 @@ mips_option_override (void)
     error ("unsupported combination: %s", "-mfp64 -mfpxx");
   else if (ISA_MIPS1 && !TARGET_FLOAT32)
     error ("%<-march=%s%> requires %<-mfp32%>", mips_arch_info->name);
-  else if (TARGET_FLOATXX && !mips_lra_flag)
-    error ("%<-mfpxx%> requires %<-mlra%>");
 
   /* End of code shared with GAS.  */
 
@@ -22871,14 +22869,6 @@ mips_spill_class (reg_class_t rclass ATTRIBUTE_UNUSED,
   return NO_REGS;
 }
 
-/* Implement TARGET_LRA_P.  */
-
-static bool
-mips_lra_p (void)
-{
-  return mips_lra_flag;
-}
-
 /* Implement TARGET_IRA_CHANGE_PSEUDO_ALLOCNO_CLASS.  */
 
 static reg_class_t
@@ -23307,8 +23297,6 @@ mips_bit_clear_p (enum machine_mode mode, unsigned HOST_WIDE_INT m)
 
 #undef TARGET_SPILL_CLASS
 #define TARGET_SPILL_CLASS mips_spill_class
-#undef TARGET_LRA_P
-#define TARGET_LRA_P mips_lra_p
 #undef TARGET_IRA_CHANGE_PSEUDO_ALLOCNO_CLASS
 #define TARGET_IRA_CHANGE_PSEUDO_ALLOCNO_CLASS mips_ira_change_pseudo_allocno_class
 
index 26f758c90ddf9d04510644cd8e215a682b805e31..7de85123e7c238e28be927578e0cf3aa7540997a 100644 (file)
    (set_attr "mode"    "SI")
    (set_attr "insn_count" "1,1,2")
    (set (attr "enabled")
-        (cond [(and (eq_attr "alternative" "0")
-                    (match_test "!mips_lra_flag"))
-                  (const_string "yes")
-               (and (eq_attr "alternative" "1")
-                    (match_test "mips_lra_flag"))
-                  (const_string "yes")
-               (eq_attr "alternative" "2")
+        (cond [(eq_attr "alternative" "1,2")
                   (const_string "yes")]
               (const_string "no")))])
 
    (set_attr "mode"    "SI")
    (set_attr "insn_count" "1,1,1,2")
    (set (attr "enabled")
-        (cond [(and (eq_attr "alternative" "0")
-                    (match_test "!mips_lra_flag"))
-                  (const_string "yes")
-               (and (eq_attr "alternative" "1")
-                    (match_test "mips_lra_flag"))
-                  (const_string "yes")
-               (eq_attr "alternative" "2,3")
+        (cond [(eq_attr "alternative" "1,2,3")
                   (const_string "yes")]
               (const_string "no")))])
 
    (set_attr "mode"     "SI")
    (set_attr "insn_count" "1,1,2")
    (set (attr "enabled")
-        (cond [(and (eq_attr "alternative" "0")
-                    (match_test "!mips_lra_flag"))
-                  (const_string "yes")
-               (and (eq_attr "alternative" "1")
-                    (match_test "mips_lra_flag"))
-                  (const_string "yes")
-               (eq_attr "alternative" "2")
+        (cond [(eq_attr "alternative" "1,2")
                   (const_string "yes")]
               (const_string "no")))])
 
index c1abb36212f98705288841e073b2021d27e5e07c..99fe93019004fa2fd0308c709852ee3af5b418fe 100644 (file)
@@ -413,10 +413,6 @@ msynci
 Target Mask(SYNCI)
 Use synci instruction to invalidate i-cache.
 
-mlra
-Target Var(mips_lra_flag) Init(1) Save
-Use LRA instead of reload.
-
 mlxc1-sxc1
 Target Var(mips_lxc1_sxc1) Init(1)
 Use lwxc1/swxc1/ldxc1/sdxc1 instructions where applicable.
index 9d166646d65cdf18382aacc195c2548f52d6efdc..5921d6929b2877ab1642c8181fed5a09a0ba51c5 100644 (file)
@@ -222,8 +222,6 @@ UrlSuffix(gcc/MIPS-Options.html#index-msym32)
 msynci
 UrlSuffix(gcc/MIPS-Options.html#index-msynci)
 
-; skipping UrlSuffix for 'mlra' due to finding no URLs
-
 mlxc1-sxc1
 UrlSuffix(gcc/MIPS-Options.html#index-mlxc1-sxc1)