Re: [PATCH] gcc: add GCC64 configuration for AIX 7.1

2020-07-24 Thread David Edelsohn via Gcc-patches
On Fri, Jul 24, 2020 at 5:01 AM CHIGOT, CLEMENT  wrote:
>
> Description:
>   This patch adds the support to build 64bit GCC applications on AIX 7.1

The patch was not correct because defaultaix64.h substitutes POWER7
target default in 64 bit mode, which AIX 7.1 defaults to POWER4.

PPC64 Linux uses BI_ARCH to specify 32 bit supporting 64 bit or 64 bit
supporting 32 bit.  AIX already does that by default.  So I changed
aix71.h and aix72.h to "abuse" BI_ARCH to flag that this is a 64 bit
default build.  This allows the choice of TARGET_DEFAULT to be
determined in aix71.h and aix72.h.  defaultaix64.h becomes redundant
and is removed.

I committed the attached, revised patch.

Thanks, David


0001-aix-Support-GCC64-for-AIX-7.1.patch
Description: Binary data


[PATCH] gcc: add GCC64 configuration for AIX 7.1

2020-07-24 Thread CHIGOT, CLEMENT via Gcc-patches
Description:
  This patch adds the support to build 64bit GCC applications on AIX 7.1

Changelog:
2020-07-24 Clement Chigot 

   * config.gcc: Use t-aix64, biarch64 and default64 for cpu_is_64bit.
   * config/rs6000/aix71.h (ASM_SPEC): Remove aix64 option.
   (ASM_SPEC32): New.
   (ASM_SPEC64): New.
   (ASM_CPU_SPEC): Remove vsx and altivec options.
   (CPP_SPEC_COMMON): Rename from CPP_SPEC.
   (CPP_SPEC32): New.
   (CPP_SPEC64): New.
   (CPLUSPLUS_CPP_SPEC): Rename to CPLUSPLUS_CPP_SPEC_COMMON..
   (TARGET_DEFAULT): Only define if not BIARCH.
   (LIB_SPEC_COMMON): Rename from LIB_SPEC.
   (LIB_SPEC32): New.
   (LIB_SPEC64): New.
   (LINK_SPEC_COMMON): Rename from LINK_SPEC.
   (LINK_SPEC32): New.
   (LINK_SPEC64): New.
   (STARTFILE_SPEC): Add 64 bit version of crtcxa and crtdbase.
   (ASM_SPEC): Define 32 and 64 bit alternatives using DEFAULT_ARCH64_P.
   (CPP_SPEC): Same.
   (CPLUSPLUS_CPP_SPEC): Same.
   (LIB_SPEC): Same.
   (LINK_SPEC): Same.
   (SUBTARGET_EXTRA_SPECS): Add new 32/64 specs.



Please apply for me if approved


Clément Chigot
ATOS Bull SAS
1 rue de Provence - 38432 Échirolles - France



0001-gcc-add-GCC64-configuration-for-AIX-7.1.patch
Description: 0001-gcc-add-GCC64-configuration-for-AIX-7.1.patch