]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
m68k: Add -mlra
authorAndreas Schwab <schwab@linux-m68k.org>
Mon, 19 Aug 2024 18:59:13 +0000 (20:59 +0200)
committerAndreas Schwab <schwab@linux-m68k.org>
Mon, 19 Aug 2024 19:38:47 +0000 (21:38 +0200)
PR target/113939
* config/m68k/m68k.opt (mlra): New target option.
* config/m68k/m68k.cc (m68k_use_lra_p): New function.
(TARGET_LRA_P): Use it.
* config/m68k/m68k.opt.urls: Regenerate.

gcc/config/m68k/m68k.cc
gcc/config/m68k/m68k.opt
gcc/config/m68k/m68k.opt.urls

index 79ba4d5343cff5732835282ca0785d7a5ea55339..21c94981d220d2287f6c549cd2e78637baaab3d1 100644 (file)
@@ -199,6 +199,7 @@ static machine_mode m68k_promote_function_mode (const_tree, machine_mode,
 static void m68k_asm_final_postscan_insn (FILE *, rtx_insn *insn, rtx [], int);
 static HARD_REG_SET m68k_zero_call_used_regs (HARD_REG_SET);
 static machine_mode m68k_c_mode_for_floating_type (enum tree_index);
+static bool m68k_use_lra_p (void);
 \f
 /* Initialize the GCC target structure.  */
 
@@ -307,7 +308,7 @@ static machine_mode m68k_c_mode_for_floating_type (enum tree_index);
 #endif
 
 #undef TARGET_LRA_P
-#define TARGET_LRA_P hook_bool_void_false
+#define TARGET_LRA_P m68k_use_lra_p
 
 #undef TARGET_LEGITIMATE_ADDRESS_P
 #define TARGET_LEGITIMATE_ADDRESS_P    m68k_legitimate_address_p
@@ -7228,4 +7229,12 @@ m68k_c_mode_for_floating_type (enum tree_index ti)
   return default_mode_for_floating_type (ti);
 }
 
+/* Implement TARGET_LRA_P.  */
+
+static bool
+m68k_use_lra_p ()
+{
+  return m68k_lra_p;
+}
+
 #include "gt-m68k.h"
index b2ab41a758f5d5667389d076fed94cd4d0adee5c..1b393f54e3c58056c504f3715ddccdd5ee10f9d8 100644 (file)
@@ -146,6 +146,11 @@ mlong-jump-table-offsets
 Target RejectNegative Mask(LONG_JUMP_TABLE_OFFSETS)
 Use 32-bit offsets in jump tables rather than 16-bit offsets.
 
+mlra
+Target Var(m68k_lra_p) Undocumented
+Usa LRA for reload instead of the old reload framework.  This option is
+experimental, and it may be removed in future versions of the compiler.
+
 mnobitfield
 Target RejectNegative InverseMask(BITFIELD)
 Do not use the bit-field instructions.
index 079fbf4a88e4bf2c24218cbb7b8431745debb30f..1f1ac88bcb2e454b5f625629b56f709275ef25b4 100644 (file)
@@ -77,6 +77,8 @@ UrlSuffix(gcc/M680x0-Options.html#index-mhard-float-2)
 mlong-jump-table-offsets
 UrlSuffix(gcc/M680x0-Options.html#index-mlong-jump-table-offsets)
 
+; skipping UrlSuffix for 'mlra' due to finding no URLs
+
 mnobitfield
 UrlSuffix(gcc/M680x0-Options.html#index-mnobitfield)