https://gcc.gnu.org/g:c361001019bc64668ac7187e91a670042109d7b9

commit c361001019bc64668ac7187e91a670042109d7b9
Author: Michael Meissner <meiss...@linux.ibm.com>
Date:   Sat Nov 16 00:48:16 2024 -0500

    Update ChangeLog.*

Diff:
---
 gcc/ChangeLog.meissner | 127 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 127 insertions(+)

diff --git a/gcc/ChangeLog.meissner b/gcc/ChangeLog.meissner
index 49826411141c..5657110e7a6a 100644
--- a/gcc/ChangeLog.meissner
+++ b/gcc/ChangeLog.meissner
@@ -1,3 +1,130 @@
+==================== Branch work186, patch #91 ====================
+
+Use architecture flags for defining _ARCH_PWR macros.
+
+For the newer architectures, this patch changes GCC to define the _ARCH_PWR<n>
+macros using the new architecture flags instead of relying on isa options like
+-mpower10.
+
+The -mpower8-internal, -mpower10, -mpower11, and -mfuture options were removed.
+The -mpower11 and -mfuture options were removed completely, since they were 
just
+added in GCC 15. The other two options were marked as WarnRemoved, and the
+various ISA bits were removed.
+
+TARGET_POWER8, TARGET_POWER10, TARGET_POWER11, and TARGET_FUTURE were 
re-defined
+to use the architeture bits instead of the ISA bits.
+
+There are other internal isa bits that aren't removed with this patch because
+the built-in function support uses those bits.
+
+I have built both big endian and little endian bootstrap compilers and there
+were no regressions.
+
+Can I install this patch on the GCC 15 trunk?
+
+2024-11-16  Michael Meissner  <meiss...@linux.ibm.com>
+
+gcc/
+
+       * config/rs6000/rs6000-c.cc (rs6000_target_modify_macros) Add support to
+       use architecture flags instead of ISA flags for setting most of the
+       _ARCH_PWR* macros.
+       (rs6000_cpu_cpp_builtins): Update rs6000_target_modify_macros call.
+       * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Remove
+       OPTION_MASK_POWER8.
+       (ISA_3_1_MASKS_SERVER): Remove OPTION_MASK_POWER10.
+       (POWER11_MASKS_SERVER): Remove OPTION_MASK_POWER11.
+       (FUTURE_MASKS_SERVER): Remove OPTION_MASK_FUTURE.
+       (POWERPC_MASKS): Remove OPTION_MASK_POWER8, OPTION_MASK_POWER10,
+       OPTION_MASK_POWER11, and OPTION_MASK_FUTURE.
+       * config/rs6000/rs6000-protos.h (rs6000_target_modify_macros): Update
+       declaration.
+       (rs6000_target_modify_macros_ptr): Likewise.
+       * config/rs6000/rs6000.cc (rs6000_target_modify_macros_ptr): Likewise.
+       (rs6000_option_override_internal): Use architecture flags instead of ISA
+       flags.
+       (rs6000_opt_masks): Remove -mpower10, -mpower11, and -mfuture which are
+       no longer in the ISA flags.
+       (rs6000_pragma_target_parse): Use architecture flags as well as ISA
+       flags.
+       * config/rs6000/rs6000.h (TARGET_POWER5): Redefine to use architecture
+       flags.
+       (TARGET_POWER5X): Likewise.
+       (TARGET_POWER6): Likewise.
+       (TARGET_POWER7): Likewise.
+       (TARGET_POWER8): Likewise.
+       (TARGET_POWER9): Likewise.
+       (TARGET_POWER10): New macro.
+       (TARGET_POWER11): Likewise.
+       (TARGET_FUTRE): Likewise.
+       * config/rs6000/rs6000.opt (-mpower8-internal): Remove ISA flag bits.
+       (-mpower10): Likewise.
+       (-mpower11): Likewise.
+       (-mfuture): Likewise.
+
+==================== Branch work186, patch #90 ====================
+
+Add rs6000 architecture masks.
+
+This patch begins the journey to move architecture bits that are not user ISA
+options from rs6000_isa_flags to a new targt variable rs6000_arch_flags.  The
+intention is to remove switches that are currently isa options, but the user
+should not be using this particular option. For example, we want users to use
+-mcpu=power10 and not just -mpower10.
+
+This patch also changes the target_clones support to use an architecture mask
+instead of isa bits.
+
+This patch also switches the handling of .machine to use architecture masks if
+they exist (power4 through power11).  All of the other PowerPCs will continue 
to
+use the existing code for setting the .machine option.
+
+I have built both big endian and little endian bootstrap compilers and there
+were no regressions.
+
+In addition, I constructed a test case that used every archiecture define (like
+_ARCH_PWR4, etc.) and I also looked at the .machine directive generated.  I ran
+this test for all supported combinations of -mcpu, big/little endian, and 32/64
+bit support.  Every single instance generated exactly the same code with the
+patches installed compared to the compiler before installing the patches.
+
+The only difference in this patch compared to the first version posted on
+November 6th is that I the correct attribution and copyright year (i.e. that I
+created rs6000-arch.def in 2024).
+
+Can I install this patch on the GCC 15 trunk?
+
+2024-11-16  Michael Meissner  <meiss...@linux.ibm.com>
+
+gcc/
+
+       * config/rs6000/default64.h (TARGET_CPU_DEFAULT): Set default cpu name.
+       * config/rs6000/rs6000-arch.def: New file.
+       * config/rs6000/rs6000.cc (struct clone_map): Switch to using
+       architecture masks instead of ISA masks.
+       (rs6000_clone_map): Likewise.
+       (rs6000_print_isa_options): Add an architecture flags argument, change
+       all callers.
+       (get_arch_flag): New function.
+       (rs6000_debug_reg_global): Update rs6000_print_isa_options calls.
+       (rs6000_option_override_internal): Likewise.
+       (rs6000_machine_from_flags): Switch to using architecture masks instead
+       of ISA masks.
+       (struct rs6000_arch_mask): New structure.
+       (rs6000_arch_masks): New table of architecutre masks and names.
+       (rs6000_function_specific_save): Save architecture flags.
+       (rs6000_function_specific_restore): Restore architecture flags.
+       (rs6000_function_specific_print): Update rs6000_print_isa_options calls.
+       (rs6000_print_options_internal): Add architecture flags options.
+       (rs6000_clone_priority): Switch to using architecture masks instead of
+       ISA masks.
+       (rs6000_can_inline_p): Don't allow inling if the callee requires a newer
+       architecture than the caller.
+       * config/rs6000/rs6000.h: Use rs6000-arch.def to create the architecture
+       masks.
+       * config/rs6000/rs6000.opt (rs6000_arch_flags): New target variable.
+       (x_rs6000_arch_flags): New save/restore field for rs6000_arch_flags.
+
 ==================== Branch work186, patch #80 ====================
 
 Do not allow -mvsx to boost processor to power7.

Reply via email to