From: "Maciej W. Rozycki" <macro@orcam.me.uk>
To: YunQiang Su <syq@debian.org>
Cc: Richard Sandiford <richard.sandiford@arm.com>,
Nick Clifton <nickc@redhat.com>,
YunQiang Su <yunqiang.su@cipunited.com>,
binutils@sourceware.org, xry111@xry111.site,
jiaxun.yang@flygoat.com
Subject: Re: [PATCH v4 1/2] MIPS: support mips*64 as CPU and gnuabi64 as ABI
Date: Tue, 1 Aug 2023 23:52:22 +0100 (BST) [thread overview]
Message-ID: <alpine.DEB.2.21.2308011120000.10240@angie.orcam.me.uk> (raw)
In-Reply-To: <CAKcpw6W_MkPaTSEc_y0sZTzXWAOkTTRs5mDGE4c6zjNSwf54_g@mail.gmail.com>
On Mon, 31 Jul 2023, YunQiang Su wrote:
> > Why would you want to make it different for `isa64' then? Say
> > `mipsisa64-*-*' for a 32-bit configuration and then `mips64isa64-*-*' for
> > a 64-bit one. In fact it already works like this: you can use
> > `mips64isa64r6-linux-gnu' and `mips64isa64r6el-linux-gnu' for your Debian
> > system right away and get what you need, there's nothing to change.
>
> Let's go back to 10 years ago, the commit
> 5afd44e33b13b922760a41580020f941dbdd473e of GCC
> which is the previous commit of MIPS r6 support is added.
> Let's have a glance of gcc/config.gcc:
>
> There are bellow lines:
> mips*-*-linux*) # Linux MIPS, either endian.
> tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h
> glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h
> mips/linux-common.h"
> extra_options="${extra_options} linux-android.opt"
> case ${target} in
> mipsisa32r2*)
> default_mips_arch=mips32r2
> ;;
> mipsisa32*)
> default_mips_arch=mips32
> ;;
> mips64el-st-linux-gnu)
> default_mips_abi=n32
> tm_file="${tm_file} mips/st.h"
> tmake_file="${tmake_file} mips/t-st"
> enable_mips_multilibs="yes"
> ;;
> mips64octeon*-*-linux*)
> default_mips_abi=n32
> tm_defines="${tm_defines}
> MIPS_CPU_STRING_DEFAULT=\\\"octeon\\\""
> target_cpu_default=MASK_SOFT_FLOAT_ABI
> enable_mips_multilibs="yes"
> ;;
> mipsisa64r2*-*-linux*)
> default_mips_abi=n32
> default_mips_arch=mips64r2
> enable_mips_multilibs="yes"
> ;;
> mips64*-*-linux* | mipsisa64*-*-linux*)
> default_mips_abi=n32
> enable_mips_multilibs="yes"
> ;;
> esac
>
>
> I don't think that it is a good idea that they are different between
> GCC and binutils.
Now this I find a valid argument, which if given with the original
submission (as a separate change from n64 though) could have prevented all
the recent controversy. As regrettable as I find the ABI inconsistency
introduced to GCC with this interpretation of `mipsisa64*-*-linux*', it's
been a part of our toolchain for long and I don't feel like it would be a
good idea to back it out now.
The inconsistency is worse yet AFAICS, because while `mipsisa32r2' and
`mipsisa64r2' set the default architecture respectively to `mips32r2' and
`mips64r2', the fallback suffixes make the random choice of `mips32' (r1)
for `mipsisa32*' (so also e.g. for `mipsisa32r5') and nothing, presumably
`mips3', for `mipsisa64*'. What a mess!
If you submit a suitably described change to synchronise this default ABI
interpretation (but for `mipsisa64*-*-linux*' only rather than extending
it to `mips*64*-*-linux*'), then we can start from there. Also it's not
commit 5afd44e33b13, which I find rather unrelated, but commit
f2d6ca5081ba, even earlier, that added this broken interpretation of
`mipsisa64*-*-linux*'.
NB please trim your replies and quote the relevant parts only to save the
reader's bandwidth.
Maciej
next prev parent reply other threads:[~2023-08-01 22:52 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-08 4:30 [PATCH 1/3] MIPS: Fix test failure with FPXX GCC YunQiang Su
2021-03-08 4:30 ` [PATCH 2/3] MIPS: default output r6 object if configured to r6 YunQiang Su
2023-02-23 11:11 ` [PATCH] MIPS: support specify isa level when configure YunQiang Su
2023-03-30 16:53 ` Richard Sandiford
2023-04-03 11:06 ` [PATCH v2] MIPS: the default output fellows triple and with-arch YunQiang Su
2023-04-03 12:40 ` Richard Sandiford
2023-04-10 7:01 ` YunQiang Su
2023-04-14 7:20 ` [PATCH v3] MIPS: the default output fellows triple YunQiang Su
2023-04-18 13:07 ` Richard Sandiford
2023-04-18 14:00 ` [PATCH v4 1/2] MIPS: support mips*64 as CPU and gnuabi64 as ABI YunQiang Su
2023-04-18 14:00 ` [PATCH v4 2/2] MIPS: default output r6 obj if the triple is r6 YunQiang Su
2023-04-19 19:03 ` Richard Sandiford
2023-04-20 13:31 ` [PATCH v5 1/2] MIPS: support mips*64 as CPU and gnuabi64 as ABI YunQiang Su
2023-04-20 13:31 ` [PATCH v5 2/2] MIPS: default output r6 obj if the triple is r6 YunQiang Su
2023-04-19 19:00 ` [PATCH v4 1/2] MIPS: support mips*64 as CPU and gnuabi64 as ABI Richard Sandiford
2023-07-21 10:00 ` Maciej W. Rozycki
2023-07-21 10:14 ` YunQiang Su
2023-07-21 11:54 ` Maciej W. Rozycki
2023-07-21 12:30 ` YunQiang Su
2023-07-21 14:30 ` Maciej W. Rozycki
2023-07-21 15:01 ` YunQiang Su
2023-07-22 7:18 ` Xi Ruoyao
2023-07-25 13:30 ` Nick Clifton
2023-07-25 14:00 ` YunQiang Su
2023-07-25 16:03 ` Maciej W. Rozycki
2023-07-31 10:05 ` Maciej W. Rozycki
2023-07-31 10:32 ` YunQiang Su
2023-08-01 22:52 ` Maciej W. Rozycki [this message]
2023-07-25 17:47 ` Andreas K. Huettel
2023-07-28 5:42 ` YunQiang Su
2023-07-25 17:41 ` Andreas K. Huettel
2021-03-08 4:30 ` [PATCH 3/3] MIPS: Fix testcase for MIPSr6 YunQiang Su
2021-03-19 5:47 ` 回复: [PATCH 1/3] MIPS: Fix test failure with FPXX GCC yunqiang.su
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.2.21.2308011120000.10240@angie.orcam.me.uk \
--to=macro@orcam.me.uk \
--cc=binutils@sourceware.org \
--cc=jiaxun.yang@flygoat.com \
--cc=nickc@redhat.com \
--cc=richard.sandiford@arm.com \
--cc=syq@debian.org \
--cc=xry111@xry111.site \
--cc=yunqiang.su@cipunited.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).