From: Ard Biesheuvel <ard.biesheuvel@linaro.org>
To: Michael Zimmermann <sigmaepsilon92@gmail.com>
Cc: valerij zaporogeci <vlrzprgts@gmail.com>,
edk2-devel <edk2-devel@lists.01.org>,
Leif Lindholm <leif.lindholm@linaro.org>
Subject: Re: Toolchain question
Date: Tue, 9 Aug 2016 08:09:16 +0200 [thread overview]
Message-ID: <CAKv+Gu-Mt+TF2ywZLcFwHqsGbcrRz-oxV+xb-ZiegwswPdmOHw@mail.gmail.com> (raw)
In-Reply-To: <CAN9vWDL3-ZUL+=W-XYw5OTcX8uSvDPFMFhiT-=s4Q0uMETwL7A@mail.gmail.com>
On 9 August 2016 at 06:07, Michael Zimmermann <sigmaepsilon92@gmail.com> wrote:
> Hi,
>
> I assume that you are using linux because you're talking about ELF files.
> MinGW may be able to compile PE images in Linux but tbh there's no reason
> for that and the "freaking" translation is actually a pretty good
> implementation and works very well.
>
Agreed. I suppose Microsoft may offer a toolchain that targets Windows
RT (if that still exists) but free implementations like GCC and Clang
are not likely to implement this any time soon, simply because, other
than UEFI, there are no use cases.
The ELF translation may be a bit clunky, but it is very effective, and
allows us to use a wide range of toolchains: RVCT (ARM only), GCC and
Clang, all of which are under constant development.
> As for the kind of toolchain to use: there's always (at least) two types:
> bare metal toolchains(arm-eabi,arm-none-eabi, aarch64-elf), and the ones
> with a OS ABI(androideabi, linux-gnueabi,linux-gnueabihf, ...). While unlike
> other bootloader/kernel projects EDK2 seems to work with all of them I can
> only recommend using the bare metal variants.
>
I use both, and never notice any difference. The primary differences
are newlib vs glibc, and in some cases, whether symbols are decorated
with a leading _
The actual code generation is more dependent on the default target
(i.e., -march/-mthumb for ARM) than bare-metal/hosted.
> For ARM and AArch64 I recommend using linaro's latest stable release(5.3 at
> the time of writing):
> http://www.linaro.org/downloads/
> sometimes the website is out of date and you can go here directly:
> https://releases.linaro.org/components/toolchain/binaries/
>
> I've also CC'ed the Arm maintainers so you'll actually get answers unlike me
> when I asked the same question about a year ago ;)
>
We have had good results enabling LTO for GCC5. However, we only
recently added support for this, and Tianocore needs some tweaks that
ordinary glibc based environments do not need to enable LTO. Please
report any issues you see with GCC5, or switch to GCC49 (which works
fine for GCC 5.x toolchains as well, but does not enable LTO)
--
Ard.
next prev parent reply other threads:[~2016-08-09 6:09 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-09 0:29 Toolchain question valerij zaporogeci
2016-08-09 4:07 ` Michael Zimmermann
2016-08-09 6:09 ` Ard Biesheuvel [this message]
2016-08-09 8:39 ` Leif Lindholm
2016-08-09 9:02 ` Michael Zimmermann
2016-08-09 10:02 ` Leif Lindholm
2016-08-09 10:04 ` Ard Biesheuvel
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-list 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=CAKv+Gu-Mt+TF2ywZLcFwHqsGbcrRz-oxV+xb-ZiegwswPdmOHw@mail.gmail.com \
--to=devel@edk2.groups.io \
/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