[PATCH 1/8] ld: Rename aarch64pe emulation target to arm64pe

Tamar Christina Tamar.Christina@arm.com
Wed Jan 4 11:08:55 GMT 2023


> -----Original Message-----
> From: Martin Storsjö <martin@martin.st>
> Sent: Wednesday, January 4, 2023 11:00 AM
> To: Tamar Christina <Tamar.Christina@arm.com>
> Cc: nickc@redhat.com; Mark Harmstone <mark@harmstone.com>; Andrew
> Pinski <pinskia@gmail.com>; Richard Earnshaw
> <Richard.Earnshaw@foss.arm.com>; NightStrike <nightstrike@gmail.com>;
> wej22007@outlook.com; zac.walker@linaro.org; binutils
> <binutils@sourceware.org>
> Subject: RE: [PATCH 1/8] ld: Rename aarch64pe emulation target to arm64pe
> 
> On Wed, 4 Jan 2023, Tamar Christina wrote:
> 
> >> -----Original Message-----
> >> From: Martin Storsj� <martin@martin.st>
> >> Sent: Wednesday, January 4, 2023 10:25 AM
> >> To: nickc@redhat.com
> >> Cc: Mark Harmstone <mark@harmstone.com>; Tamar Christina
> >> <Tamar.Christina@arm.com>; Andrew Pinski <pinskia@gmail.com>;
> Richard
> >> Earnshaw <Richard.Earnshaw@foss.arm.com>; NightStrike
> >> <nightstrike@gmail.com>; wej22007@outlook.com;
> zac.walker@linaro.org;
> >> binutils <binutils@sourceware.org>
> >> Subject: Re: [PATCH 1/8] ld: Rename aarch64pe emulation target to
> >> arm64pe
> >>
> >> On Wed, 4 Jan 2023, Nick Clifton wrote:
> >>
> >>> This would create duplicated code sure, but not too much, and it
> >>> would allow the linker to be compatible with Clang whilst still also
> >>> retaining the aarch64 moniker preferred by ARM.
> >>
> >> As this still is framed as "compatible with Clang" - does this mean
> >> that you still insist that GCC should use a different emulation name
> >> when calling the linker, than what Clang does, forcing lld to also
> >> start recognizing that new, different emulation name - different from
> >> the one that has been in place for
> >> 5 years?
> >
> > To be clear, GCC will very likely reject any port upstreaming that
> > uses
> > Arm64 for the same reason.  And GCC is a lot more tightly controlled.
> > At least if you want upstream support.
> >
> > Believe it or not I'm actually trying to help you here, the fact that
> > clang has called it arm64 is why we want to allow the alias.  As I
> > mentioned before, it just can't be the main name.
> 
> Right - but in the case of GCC, it wouldn't be the name of a new port - it
> would only be a single word in a file for passing linker arguments. Just like
> how "-m i386pep" is passed for x86_64 today here:
> https://github.com/gcc-
> mirror/gcc/blob/345dffd0d4ebff7e705dfff1a8a72017a167120a/gcc/config/i38
> 6/mingw-w64.h#L74
> 
> So regardless of the binutils discussion, are you saying that GCC would reject
> a patch that adds such an occurance that would pass "-m arm64pe", in a
> patch that otherwise consistently calls the port "aarch64"?

If it's driver only and has no source implications then It might be ok.  But look at this
patch, it's not driver only. By renaming the emulation target it also renamed the internal
macros.  It makes us have to maintain the name "arm64" in the source code along with
what everything else calls aarch64 and this has more implications.

Tamar
> 
> // Martin


More information about the Binutils mailing list