On Wed, Apr 25, 2018 at 10:21 AM, Ted Mielczarek <t...@mielczarek.org> wrote:

> On Wed, Apr 25, 2018, at 12:32 PM, Jeff Muizelaar wrote:
> > At minimum we should make --enable-profiling build with rust-opt.
>
> This sounds reasonable, although the quirk is that we default
> --enable-profiling on for nightly[1], so anyone building m-c will have it
> enabled. We could make the build system only do this for "explicitly
> enabled --enable-profiling", it just might be slightly confusing. (For
> reference, the rustc opt level is controlled here[2].)
>

We could also change this default. In general, Nightly is usually fine for
profiling, so I think the set of people doing local builds for profiling is
small enough that we could reasonably expect them to set the flag in their
mozconfig.


>
> IIRC the slowdown from using opt-level=2 vs. 1 is primarily in LLVM? It
> would probably be useful if we instrumented the build to record compilation
> times for all of the crates we build at various optimization levels and see
> where the biggest issues are. Perhaps we could get someone on the Rust team
> to make some improvements if we know what the worst offenders are.
>

Well, there's the opt level thing, but there's also the much larger bit
that we don't do Rust LTO without --enable-release, which IIUC has a
substantial performance impact.



>
> -Ted
>
> 1. https://dxr.mozilla.org/mozilla-central/rev/
> 26e53729a10976f52e75efa44e17b5e054969fec/js/moz.configure#243
> 2. https://dxr.mozilla.org/mozilla-central/rev/
> 26e53729a10976f52e75efa44e17b5e054969fec/build/moz.
> configure/toolchain.configure#1397
> _______________________________________________
> dev-platform mailing list
> dev-platform@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-platform
>
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to