Skip to content

[ICE]: unsupported instrumentation profile format version #139198

Closed
@yuhui518

Description

@yuhui518

Code

Affected release channels

  • Previous Stable
  • Current Stable
  • Current Beta
  • Current Nightly

Rust Version

rustc --version --verbose
rustc 1.81.0 (eeb90cda1 2024-09-04)
binary: rustc
commit-hash: eeb90cda1969383f56a2637cbd3037bdf598841c
commit-date: 2024-09-04
host: x86_64-unknown-linux-gnu
release: 1.81.0
LLVM version: 18.1.7

Current error output

My issue is:
warning: /tmp/.tmpfHs8e8/cov-21560-15860613078634779016_0_1.profraw: unsupported instrumentation profile format version
error: no profile can be merged
12:42:34 [ERROR] Error while executing llvm tools: Failure while running "/linux/llvm/bin/llvm-profdata" "merge" "-f" "-" "-sparse" "-o" "/tmp/.tmpfHs8e8/0/grcov.profdata"

[root@localhost ut]# cargo -V
warning: /root/.cargo/config is deprecated in favor of config.toml
note: if you need to support cargo 1.38 or earlier, you can symlink config to config.toml
cargo 1.81.0 (2dbb1af80 2024-08-20)

[root@localhost bin]#./llvm-profdata show --version
LLVM (http://llvm.org/):
LLVM version 15.0.4
Optimized build.
Default target: x86_64-unknown-linux-gnu

[root@localhost bin]# ./clang --version
clang version 15.0.4 (llvm-project 9176a70a8154b7ab1764e6e94f6ab58bc9f9b189)
Target: x86_64-unknown-linux-gnu

Llvm-profdata and clang is same version,I don't know why this problem occurred?

Backtrace

1:build my code
RUSTFLAGS="-C instrument-coverage -C link-arg=--target=aarch64-unknown-linux-ohos -C linker=/home/llvm/bin/clang -C link-arg=-lpixman-1" cargo test --workspace --target=aarch64-unknown-linux-ohos --features "boot_time" --exclude mod_test --exclude ozone --no-run
2.run my binary file
export STRATOVIRT_COV=on  && export LLVM_PROFILE_FILE=/data/coverage/mst/profraw/cov-%%p-%%m.profraw
./boot_time --test-threads=1
3.put /data/coverage/mst/profraw/cov-%%p-%%m.profraw to my directory
4.grcov ../profraw -s . --binary-path ./target/aarch64-unknown-linux-ohos/debug --llvm-path /home/llvm/bin/ -t html -o ../ut-cov

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-LLVMArea: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.A-code-coverageArea: Source-based code coverage (-Cinstrument-coverage)C-bugCategory: This is a bug.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