[PATCH] D156611: [llvm-cov] Fix a bug about using `convert-for-testing` on multi-source object files

Douglas Yung via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 15 12:01:11 PDT 2023


dyung added a comment.

In D156611#4587837 <https://reviews.llvm.org/D156611#4587837>, @AtomicGu wrote:

> @dyung Here is a patch for converting. Use this patch by `git apply`. As I said, it's very rudimentary and for temporary use.
>
> To use it, set an environment variable `LLVM_COV_NEW_TESTING_FORMAT_CVT` with an output path of the new .covmapping file. Then run `llvm-cov report` on previous .covmapping files. You need to specify the option `--instr-profile` as well to make `llvm-cov` start successfully, although it won't affect the output.
>
> For example:
>
>   LLVM_COV_NEW_TESTING_FORMAT_CVT=path/to/main.covmapping2 \
>   llvm-cov report --instr-profile any/profdata/will/do main.covmapping
>
> F28701518: diff.patch <https://reviews.llvm.org/F28701518>
>
> However, use it cautiously. I don't know whether we will revert this path or not. How do you think? As an actual downstream user, do you think we should keep the backward compatibility, or provide a formal tool (like a new option to `convert-for-testing`) to convert the old format files?
>
> Please reply to me as soon as possible. I will fix this at once when the decision is made.

Thanks for this @AtomicGu, I'll give that a try. We have private changes downstream that when it was implemented a test was added which used `.covmapping` files and that is what I need to update. It's not really something we ship to customers, so really all I am doing is what you did here, updating the tests.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156611/new/

https://reviews.llvm.org/D156611



More information about the llvm-commits mailing list