On Thu, May 10, 2018 at 5:35 PM, Anthony Jones <ajo...@mozilla.com> wrote:

> You may already know that the Low-Level Tools team support important tools
> and code infrastructure. Lately we’ve also been improving our rustc/clang
> (LLVM) story and I’d like bring everyone up to date.
>
> There are a lot of important and interesting things going on:
>
>     * Michael Woerister and Nathan Froyd recently (mid-March) enabled Rust
> incremental compilation for Firefox developers
>     * Michael is experimenting with cross language inlining[1]
> (rustc/clang) using LTO
>         * Preliminary results show compiling LLVM with clang and using LTO
> on rustc improves stylo compilation time by around 15% [on-my-machine
> measurements]
>         * LTO requires more work to support Firefox
>     * Nick Nethercote has started speeding up rustc[2] and has already had
> a number of wins
>     * David Major has got Windows clang builds working with green tests
>         * LTO is still buggy (but works well enough to run benchmarks) and
> PGO won’t run on Windows
>         * Win32 - clang with LTO w/o PGO is marginally faster than MSVC
> with LTO/PGO
>         * Win64 - clang with LTO w/o PGO is ~5-10% slower than MSVC with
> LTO/PGO
>         * Windows users can build locally with clang[3]
>     * Mike Hommey is tracking improvements and regressions in the Rust
> compiler (performance regression[4], crash reporting[5] and more crash
> reporting[6])
>     * Tom Tromey is continuing to work on first class Rust support in GDB
> and LLDB
>
> Note: this a summary of things rustc/clang stuff that is happening only.
>
> Ultimately, I’d like to see us standardise on clang on all platforms
> because it makes Rust/C++ integration better as well as making things
> simpler for developers and build system maintainers. We’ll get more done if
> we make our own lives simpler.
>
> I have some specific requests for you:
>
>     Let me know if you have specific Firefox related cases where Rust is
> slowing you down (thanks Jeff [7])
>     Cross language inlining is coming - avoid duplication between Rust and
> C++ in the name of performance
>     Do developer builds with clang
>

This is all fantastic work!

Speaking as a build system maintainer, I would also like to see us
standardize on Clang on all platform for various reasons, especially
simplicity. Speaking as an open source advocate, I can't wait to be using
an open source toolchain on Windows. Speaking as someone who cares about
developer ergonomics, I can't wait until we reduce the number of toolchains
we support as tier 1 platforms so we all don't have to spend so much effort
making things work on N+1 platforms. Reducing the number of toolchains we
need to worry about is very much analogous to the security benefits of
reducing attack surface area.

I do have some concerns about dropping support for non-Clang toolchains and
what that will mean for various people who rely on them. But I think
"switching toolchains" is a separate discussion from "dropping toolchains"
and we can largely defer those discussions. As far as switching to Clang
for all builds we ship to users is concerned, I'm all aboard from the build
system side.
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to