https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112300

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2023-11-24
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
That seems like config.gcc bug for the particular target, which is the only one
which doesn't append its tm_defines to the earlier ones, but overwrites them:
grep 'tm_defines="[^$]' config.gcc 
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R6
MIPS_ABI_DEFAULT=ABI_32"
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R2
MIPS_ABI_DEFAULT=ABI_32"
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32
MIPS_ABI_DEFAULT=ABI_32"
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R6
MIPS_ABI_DEFAULT=ABI_N32"
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R2
MIPS_ABI_DEFAULT=ABI_N32"
            tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64
MIPS_ABI_DEFAULT=ABI_N32"
                                tm_defines="TARGET_ENDIAN_DEFAULT=0
$tm_defines"
So, I guess
2023-11-24  Jakub Jelinek  <ja...@redhat.com>

        PR target/112300
        * config.gcc (mips*-sde-elf*): Append to tm_defines rather than
        overwriting them.

--- gcc/config.gcc.jj   2023-11-18 09:35:20.625089143 +0100
+++ gcc/config.gcc      2023-11-24 16:41:39.194495079 +0100
@@ -2682,22 +2682,22 @@ mips*-sde-elf*)
        esac
        case ${target} in
          mipsisa32r6*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R6
MIPS_ABI_DEFAULT=ABI_32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R6
MIPS_ABI_DEFAULT=ABI_32"
            ;;
          mipsisa32r2*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R2
MIPS_ABI_DEFAULT=ABI_32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32R2
MIPS_ABI_DEFAULT=ABI_32"
            ;;
          mipsisa32*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32
MIPS_ABI_DEFAULT=ABI_32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS32
MIPS_ABI_DEFAULT=ABI_32"
            ;;
          mipsisa64r6*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R6
MIPS_ABI_DEFAULT=ABI_N32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R6
MIPS_ABI_DEFAULT=ABI_N32"
            ;;
          mipsisa64r2*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R2
MIPS_ABI_DEFAULT=ABI_N32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64R2
MIPS_ABI_DEFAULT=ABI_N32"
            ;;
          mipsisa64*)
-           tm_defines="MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64
MIPS_ABI_DEFAULT=ABI_N32"
+           tm_defines="${tm_defines} MIPS_ISA_DEFAULT=MIPS_ISA_MIPS64
MIPS_ABI_DEFAULT=ABI_N32"
            ;;
        esac
        ;;
should be the right fix, but I've never heard of mips*-sde*-elf before... ;)
>From looking at config.gcc, I think the change will add
" LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3 LIBC_MUSL=4 HEAP_TRAMPOLINES_INIT=0
"
to the start of tm_defines.

Reply via email to