Skip to content

pgo: -Cprofile-use can't find file #63609

@matthiaskrgr

Description

@matthiaskrgr
git clone https://github.com/matthiaskrgr/cargo-cache cd cargo-cache RUSTFLAGS="-Cprofile-generate=target/pgodata" cargo build --release ./target/release/cargo-cache ./target/release/cargo-cache ./target/release/cargo-cache q hello ./target/release/cargo-cache r ./target/release/cargo-cache --top-cache-items 10 llvm-profdata merge -o target/merged.profdata ./target/pgodata/ file target/merged.profdata # target/merged.profdata: LLVM indexed profile data, version 5 RUSTFLAGS="-Cprofile-use=target/merged.profdata" cargo build --release -j 1
 Compiling serde v1.0.98 error: File `target/merged.profdata` passed to `-C profile-use` does not exist. error: aborting due to previous error error: Could not compile `serde`. To learn more, run the command again with --verbose. 

The file is definitely there, but for some reason it is not found??

rustc 1.38.0-nightly (c43d03a19 2019-08-14)

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-PGOArea: Profile-guided optimizations (PGO)A-diagnosticsArea: Messages for errors, warnings, and lintsA-frontendArea: Compiler frontend (errors, parsing and HIR)C-enhancementCategory: An issue proposing an enhancement or a PR with one.T-cargoRelevant to the cargo team, which will review and decide on the PR/issue.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions