Re: [PATCH 20/23] kbuild: rust: parallelise rustc front end
From: Lorenzo Stoakes (ARM)
Date: Wed Sep 09 2026 - 10:56:55 EST
On Wed, Sep 09, 2026 at 02:59:13PM +0200, Miguel Ojeda wrote:
> On Wed, Sep 9, 2026 at 12:22 PM Björn Baron <bjorn3_gh@xxxxxxxxxxxxxx> wrote:
> >
> > There are still several known reproducibility issues for the parallel
> > frontend[1] and at least until fairly recently there were also deadlock
> > issues and incorrect errors[2], so I would not recommend enabling it without
> > an explicit request from the user. Perhaps even only allow it on nightly
> > rustc for now, then you don't need to check which of the two spellings of
> > the flag is supported.
>
> Thanks a lot for taking a look Björn.
>
> If there are still major issues even in nightly, then I would say
> let's not add it yet -- some users/CIs are testing with nightly
> routinely, so it is probably best to avoid surprises for them. (If
> someone wants to test the flag, they can still pass it manually.)
>
> On the other hand, if there are no major issues left and it is just
> reproducibility issues, then I guess we could add it to help figure
> those issues out and avoid surprises later on.
Yup, I am encouraged by 'until fairly recently' on that ;) so maybe just
bump version requirement to whatever this recently was?
>
> > By the way, currently backend parallelism is entirely disabled due to the
> > usage of --emit obj (which forces -Ccodegen-units=1). For -O2/3 builds
>
> Yeah, we even set `-Ccodegen-units=1` explicitly at the moment, so we
> would need to change that too (and likely make it an option, because
> normally end users will want the best results, while developers may
> want speed of iteration).
>
> Cheers,
> Miguel
--
Cheers, Lorenzo