Skip to content

build --release takes forever on latest rust release #119822

Description

@Qumeric

I have a project of around 10k lines and 1000 dependency crates. I cannot share it because it's closed source.

I was working on it for a few months and previously compiled it with stable, beta and nightly rust.

I decided to update rust to latest version. I run cargo build --release and it stuck at

   Compiling reth-block-validator v0.1.0 (/path/...)
   Building [=====================> ] 1157/1161: my-crate-name

I tried to build my-crate-name solely (full project is workspace) but it stuck in a same way.

I tried to do it with macOS + lld, linux + mold, linux + ld. Linux were 3 different machines with 5x00X Ryzen cpus.

It always stuck (I waited at least 10 and up to 60 minutes). Both in latest (installed with rustup) stable, beta and nightly.

I tried different standard things like cargo clean but nothing helped.

The project builds without --release just fine and builds with --release in rust 1.74.1 (and some previous versions of nightly and beta). It takes ~4 minutes for clean --release build and ~1.5 minutes for clean debug build.

I may try git bisect on compiler versions later if I will have time for that. Although I am not completely sure if it's compiler issue, could be cargo issue as well?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-compiletimeIssue: Problems and improvements with respect to compile times.S-needs-reproStatus: This issue has no reproduction and needs a reproduction to make progress.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-stablePerformance or correctness regression from one stable version to another.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions