public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/meissner/heads/work056)] Add -mconst-anchor=<x>.
@ 2021-06-28 22:26 Michael Meissner
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Meissner @ 2021-06-28 22:26 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:8fc7d6fc065c3cb6ad120de5436b3dae58ec927e

commit 8fc7d6fc065c3cb6ad120de5436b3dae58ec927e
Author: Michael Meissner <meissner@linux.ibm.com>
Date:   Mon Jun 28 18:26:24 2021 -0400

    Add -mconst-anchor=<x>.
    
    gcc/
    2021-06-28  Michael Meissner  <meissner@linux.ibm.com>
    
            * config/rs6000/rs6000.c (DEBUG_FMT_W): New debug format.
            (rs6000_debug_reg_global): Print the const_anchor size.
            (rs6000_option_override_internal): Set const_anchor if
            -mconst-anchor=<xx> is used.
            * config/rs6000/rs6000.opt (-mconst-anchor=): New switch.

Diff:
---
 gcc/config/rs6000/rs6000.c   | 7 +++++++
 gcc/config/rs6000/rs6000.opt | 4 ++++
 2 files changed, 11 insertions(+)

diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index 01a586e1b14..78ca043e191 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -2215,6 +2215,7 @@ rs6000_debug_print_mode (ssize_t m)
 
 #define DEBUG_FMT_ID "%-32s= "
 #define DEBUG_FMT_D   DEBUG_FMT_ID "%d\n"
+#define DEBUG_FMT_W   DEBUG_FMT_ID HOST_WIDE_INT_PRINT_HEX "\n"
 #define DEBUG_FMT_WX  DEBUG_FMT_ID "%#.12" HOST_WIDE_INT_PRINT "x: "
 #define DEBUG_FMT_S   DEBUG_FMT_ID "%s\n"
 
@@ -2597,6 +2598,8 @@ rs6000_debug_reg_global (void)
   if (TARGET_DIRECT_MOVE_128)
     fprintf (stderr, DEBUG_FMT_D, "VSX easy 64-bit mfvsrld element",
 	     (int)VECTOR_ELEMENT_MFVSRLD_64BIT);
+
+  fprintf (stderr, DEBUG_FMT_W, "const_anchor", targetm.const_anchor);
 }
 
 \f
@@ -4431,6 +4434,10 @@ rs6000_option_override_internal (bool global_init_p)
       && !global_options_set.x_TARGET_NO_FP_IN_TOC)
     TARGET_NO_FP_IN_TOC = 1;
 
+  /* Set the constant anchor.  */
+  if (rs6000_const_anchor)
+    targetm.const_anchor = strtoul (rs6000_const_anchor, (char **)0, 0);
+
   if (TARGET_DEBUG_REG || TARGET_DEBUG_TARGET)
     rs6000_print_isa_options (stderr, 0, "before subtarget", rs6000_isa_flags);
 
diff --git a/gcc/config/rs6000/rs6000.opt b/gcc/config/rs6000/rs6000.opt
index add22c8be1a..d3aa8e911d8 100644
--- a/gcc/config/rs6000/rs6000.opt
+++ b/gcc/config/rs6000/rs6000.opt
@@ -659,3 +659,7 @@ Generate (do not generate) LXVKQ instructions.
 mpower10-large-consts
 Target Undocumented Mask(P10_LARGE_CONSTS) Var(rs6000_isa_flags)
 Generate (do not generate) PLI/SLDI/PADDI to load large constants.
+
+mconst-anchor=
+Target Undocumented Var(rs6000_const_anchor) RejectNegative Joined Save
+Override the constant anchor.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [gcc(refs/users/meissner/heads/work056)] Add -mconst-anchor=<x>.
@ 2021-06-29  3:42 Michael Meissner
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Meissner @ 2021-06-29  3:42 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:33c22ce3538d1724d46710a7d12757641b51da20

commit 33c22ce3538d1724d46710a7d12757641b51da20
Author: Michael Meissner <meissner@linux.ibm.com>
Date:   Mon Jun 28 23:42:06 2021 -0400

    Add -mconst-anchor=<x>.
    
    gcc/
    2021-06-28  Michael Meissner  <meissner@linux.ibm.com>
    
            * config/rs6000/rs6000.c (rs6000_option_override_internal): Allow
            hardware floating point support on 32-bit.

Diff:
---
 gcc/config/rs6000/rs6000.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index 78ca043e191..c382b3287a1 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -4284,6 +4284,7 @@ rs6000_option_override_internal (bool global_init_p)
       rs6000_isa_flags &= ~OPTION_MASK_FLOAT128_HW;
     }
 
+#if 0
   if (TARGET_FLOAT128_HW && !TARGET_64BIT)
     {
       if ((rs6000_isa_flags_explicit & OPTION_MASK_FLOAT128_HW) != 0)
@@ -4291,6 +4292,7 @@ rs6000_option_override_internal (bool global_init_p)
 
       rs6000_isa_flags &= ~OPTION_MASK_FLOAT128_HW;
     }
+#endif
 
   /* Enable -mprefixed by default on power10 systems.  */
   if (TARGET_POWER10 && (rs6000_isa_flags_explicit & OPTION_MASK_PREFIXED) == 0)


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-29  3:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-28 22:26 [gcc(refs/users/meissner/heads/work056)] Add -mconst-anchor=<x> Michael Meissner
2021-06-29  3:42 Michael Meissner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).