Skip to content

x.py sometimes causes spurious rebuilds of rustc #80849

Closed
@PatchMixolydic

Description

@PatchMixolydic

I tried this:

src/test/ui/fn/issue-80844-no-gate.rs

  fn returns_generator() -> _ {
  //~^ ERROR the type placeholder `_` is not allowed within types on item signatures [E0121]
  //~| NOTE not allowed in type signatures
      || yield 0
      //~^ ERROR yield syntax is experimental
-     //~^ NOTE see issue
+     //~| NOTE see issue
  }
$ ./x.py test src/test/ui/fn

I expected to see this happen: the ui/fn test suite is run, possibly building the testsuite binary using the existing stage 1 rustc.

Instead, this happened: the stage 1 rustc is rebuilt before running the test suite.

This seems to happen randomly; I had rerun the test suite quite a few times using the same command with no issues. This is rather inconvenient since even with 16 logical cores, building rustc takes several minutes and grinds my machine to a halt.

This doesn't just seem to happen when running the test suite, but I'm less confident about saying that rebuilds after modifying rustc's codebase are spurious.

@rustbot modify labels +A-contributor-roadblock +A-rustbuild

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-contributor-roadblockArea: Makes things more difficult for new or seasoned contributors to RustC-bugCategory: This is a bug.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions