[llvm-bugs] [Bug 26294] New: Files created by insert-gcov-profiling pass unusable, errors during execution

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jan 25 10:54:25 PST 2016


https://llvm.org/bugs/show_bug.cgi?id=26294

            Bug ID: 26294
           Summary: Files created by insert-gcov-profiling pass unusable,
                    errors during execution
           Product: new-bugs
           Version: 3.7
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: bugs+llvm+org at sebastianhahn.net
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

Created attachment 15706
  --> https://llvm.org/bugs/attachment.cgi?id=15706&action=edit
created gcda file

I am trying to build a rust binary with support for coverage analysis. To this
end, I've built a compiler-rt with profiling support and linked it as well as
instructed rustc to use the inclde-gcov-profiling pass ("-C
passes=insert-gcov-profiling  -C link-args=/path/to/libcompiler_rt.a" arguments
for rustc).

When I build my rust program, a .gcno file is produced as expected, and when
running the binary a .gcda file is also created. I get a lot of errors during
.gcda creation, tho:

{{{
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000000)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000000)
...
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x726f7461)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000000)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000000)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00004565)
profiling: main.gcda: cannot merge previous GCDA file: mismatched number of
counters (26)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000001)
...
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x63655677)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x55353172)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x543c6f72)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x61725f6d)
profiling: main.gcda: cannot merge previous GCDA file: mismatched number of
counters (4)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x9d6e59a2)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x00000009)
...
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x64657265)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x2c4b3c74)
profiling: main.gcda: cannot merge previous GCDA file: corrupt arc tag
(0x324475e5)
profiling: main.gcda: cannot merge previous run count: corrupt object tag
(0x0000000f)
}}}

When using llvm-cov on the created main.gcda file like this: "llvm-cov gcov
main.gcda", I get the following output:

{{{
File checksums do not match: 2401456232 != 3219325286.
Invalid .gcda File!
}}}

I've tried this on both OSX and Linux (both 64bit) and am getting the same
issue on both platforms.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160125/e1ca55c5/attachment.html>


More information about the llvm-bugs mailing list