Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incremental compiliation is ineffective when building compiler #55500

Closed
Aaron1011 opened this issue Oct 30, 2018 · 2 comments
Closed

Incremental compiliation is ineffective when building compiler #55500

Aaron1011 opened this issue Oct 30, 2018 · 2 comments
Labels
A-incr-comp Area: Incremental compilation I-compiletime Issue: Problems and improvements with respect to compile times. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-incr-comp Working group: Incremental compilation

Comments

@Aaron1011
Copy link
Member

Aaron1011 commented Oct 30, 2018

Rebuilding the compiler took 15 minutes after simply running touch on a file. Given that nothing has actually changed, I would expect that rebuilding would be much faster.

Steps to reproduce:

  1. Clone the rust repository.
  2. Set incremental = true in the rust section of config.toml.
  3. Run ./x.py clean if you've previously built the compiler
  4. Run ./x.py build
  5. Run touch src/librustc/traits/auto_trait.rs
  6. Run ./x.py build again.

The second ./x.py build invocation takes much longer than it should (~15 minutes on my machine), considering that the only thing that's changed is a file timestamp.

@Aaron1011 Aaron1011 changed the title Incremental compiliation is ineffctive when building compiler Incremental compiliation is ineffective when building compiler Oct 30, 2018
@Centril Centril added I-compiletime Issue: Problems and improvements with respect to compile times. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) A-incr-comp Area: Incremental compilation WG-incr-comp Working group: Incremental compilation labels Oct 30, 2018
@pnkfelix pnkfelix added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Mar 29, 2019
@pnkfelix
Copy link
Member

pnkfelix commented Jun 6, 2019

It would be worth trying to figure out whether this phenomenon is due to some problem specific in the rustbuild bootstrap process, or if it something that affects other clients using incremental compilation (and therefore would be a potential blocker for turning on incremental in release mode, cc #57968)

@pnkfelix
Copy link
Member

pnkfelix commented Oct 6, 2020

discussed at wg-incr-comp meeting.

We think that the issue as described here is probably largely an artifact of the build process discussed above is building all the way to stage 2, which A. imposes work that is hard to avoid (at least automatically), and B. is no longer the default in x.py for rustc development, and thus should not be affecting most rustc developers.

closing as (presumed) "fixed" or at least "not a bug for wg-incr-comp"...

@pnkfelix pnkfelix closed this as completed Oct 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-incr-comp Area: Incremental compilation I-compiletime Issue: Problems and improvements with respect to compile times. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-incr-comp Working group: Incremental compilation
Projects
None yet
Development

No branches or pull requests

3 participants