mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-28 14:55:22 +02:00
doc: update llvm based coverage example
On some systems the old example of using xargs to pass list of profraw files can exceed xargs's argument limit resulting in multiple executions of llvm-profdata merge command which overwrites it's output file losing coverage information. Switch to using a file with a list of filenames.
This commit is contained in:
@@ -457,7 +457,8 @@ LLVM_PROFILE_FILE="$(pwd)/build/raw_profile_data/%m_%p.profraw" ctest --test-dir
|
||||
LLVM_PROFILE_FILE="$(pwd)/build/raw_profile_data/%m_%p.profraw" build/test/functional/test_runner.py # Append "-j N" here for N parallel jobs
|
||||
|
||||
# Merge all the raw profile data into a single file
|
||||
find build/raw_profile_data -name "*.profraw" | xargs llvm-profdata merge -o build/coverage.profdata
|
||||
find build/raw_profile_data -name "*.profraw" > build/raw_profile_data_files.txt
|
||||
llvm-profdata merge -f build/raw_profile_data_files.txt -o build/coverage.profdata
|
||||
```
|
||||
|
||||
> **Note:** The "counter mismatch" warning can be safely ignored, though it can be resolved by updating to Clang 19.
|
||||
|
||||
Reference in New Issue
Block a user