mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-10-25 10:27:04 +00:00
llvm-cov: Use the number of executed functions for the function coverage metric.
This commit fixes llvm-cov's function coverage metric by using the number of executed functions instead of the number of fully covered functions. Differential Revision: http://reviews.llvm.org/D5196 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@218672 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
24
test/tools/llvm-cov/report.cpp
Normal file
24
test/tools/llvm-cov/report.cpp
Normal file
@@ -0,0 +1,24 @@
|
||||
// RUN: llvm-cov report %S/Inputs/report.covmapping -instr-profile %S/Inputs/report.profdata -no-colors 2>&1 | FileCheck %s
|
||||
|
||||
// CHECK: Filename Regions Miss Cover Functions Executed
|
||||
// CHECK: TOTAL 5 2 60.00% 4 75.00%
|
||||
|
||||
void foo(bool cond) {
|
||||
if (cond) {
|
||||
}
|
||||
}
|
||||
|
||||
void bar() {
|
||||
}
|
||||
|
||||
void func() {
|
||||
}
|
||||
|
||||
int main() {
|
||||
foo(false);
|
||||
bar();
|
||||
return 0;
|
||||
}
|
||||
|
||||
// llvm-cov doesn't work on big endian yet
|
||||
// XFAIL: powerpc64-, s390x, mips-, mips64-, sparc
|
||||
Reference in New Issue
Block a user