| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,311 @@ | ||
| // Test visualization of general branch constructs in C. | ||
|
|
||
| // RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s | ||
| // RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT | ||
|
|
||
| void simple_loops() { | ||
| int i; | ||
| for (i = 0; i < 100; ++i) { // CHECK: Branch ([[@LINE]]:15): [True: 100, False: 1] | ||
| } | ||
| while (i > 0) // CHECK: Branch ([[@LINE]]:10): [True: 100, False: 1] | ||
| i--; | ||
| do {} while (i++ < 75); // CHECK: Branch ([[@LINE]]:16): [True: 75, False: 1] | ||
|
|
||
| } | ||
|
|
||
| void conditionals() { | ||
| for (int i = 0; i < 100; ++i) {// CHECK: Branch ([[@LINE]]:19): [True: 100, False: 1] | ||
| if (i % 2) { // CHECK: Branch ([[@LINE]]:9): [True: 50, False: 50] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 50, False: 0] | ||
| } else if (i % 3) { // CHECK: Branch ([[@LINE]]:16): [True: 33, False: 17] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 33, False: 0] | ||
| } else { | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 16, False: 1] | ||
| } | ||
| // CHECK: Branch ([[@LINE+1]]:9): [Folded - Ignored] | ||
| if (1 && i) {} // CHECK: Branch ([[@LINE]]:14): [True: 99, False: 1] | ||
| if (0 || i) {} // CHECK: Branch ([[@LINE]]:9): [Folded - Ignored] | ||
| } // CHECK: Branch ([[@LINE-1]]:14): [True: 99, False: 1] | ||
|
|
||
| } | ||
|
|
||
| void early_exits() { | ||
| int i = 0; | ||
|
|
||
| if (i) {} // CHECK: Branch ([[@LINE]]:7): [True: 0, False: 1] | ||
|
|
||
| while (i < 100) { // CHECK: Branch ([[@LINE]]:10): [True: 51, False: 0] | ||
| i++; | ||
| if (i > 50) // CHECK: Branch ([[@LINE]]:9): [True: 1, False: 50] | ||
| break; | ||
| if (i % 2) // CHECK: Branch ([[@LINE]]:9): [True: 25, False: 25] | ||
| continue; | ||
| } | ||
|
|
||
| if (i) {} // CHECK: Branch ([[@LINE]]:7): [True: 1, False: 0] | ||
|
|
||
| do { | ||
| if (i > 75) // CHECK: Branch ([[@LINE]]:9): [True: 1, False: 25] | ||
| return; | ||
| else | ||
| i++; | ||
| } while (i < 100); // CHECK: Branch ([[@LINE]]:12): [True: 25, False: 0] | ||
|
|
||
| if (i) {} // CHECK: Branch ([[@LINE]]:7): [True: 0, False: 0] | ||
|
|
||
| } | ||
|
|
||
| void jumps() { | ||
| int i; | ||
|
|
||
| for (i = 0; i < 2; ++i) { // CHECK: Branch ([[@LINE]]:15): [True: 1, False: 0] | ||
| goto outofloop; | ||
| // Never reached -> no weights | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:9): [True: 0, False: 0] | ||
| } | ||
|
|
||
| outofloop: | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:7): [True: 0, False: 1] | ||
|
|
||
| goto loop1; | ||
|
|
||
| while (i) { // CHECK: Branch ([[@LINE]]:10): [True: 0, False: 1] | ||
| loop1: | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:9): [True: 0, False: 1] | ||
| } | ||
|
|
||
| goto loop2; | ||
| first: | ||
| second: | ||
| third: | ||
| i++; | ||
| if (i < 3) // CHECK: Branch ([[@LINE]]:7): [True: 2, False: 1] | ||
| goto loop2; | ||
|
|
||
| while (i < 3) { // CHECK: Branch ([[@LINE]]:10): [True: 0, False: 1] | ||
| loop2: | ||
| switch (i) { | ||
| case 0: // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 2] | ||
| goto first; | ||
| case 1: // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 2] | ||
| goto second; | ||
| case 2: // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 2] | ||
| goto third; | ||
| } | ||
| } | ||
|
|
||
| for (i = 0; i < 10; ++i) { // CHECK: Branch ([[@LINE]]:15): [True: 10, False: 1] | ||
| goto withinloop; | ||
| // never reached -> no weights | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:9): [True: 0, False: 0] | ||
| withinloop: | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:9): [True: 9, False: 1] | ||
| } | ||
|
|
||
| } | ||
|
|
||
| void switches() { | ||
| static int weights[] = {1, 2, 2, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5}; | ||
|
|
||
| // No cases -> no weights | ||
| switch (weights[0]) { | ||
| default: // CHECK: Branch ([[@LINE]]:3): [True: 1, False: 0] | ||
| break; | ||
| } | ||
| // CHECK: Branch ([[@LINE+1]]:63): [True: 15, False: 0] | ||
| for (int i = 0, len = sizeof(weights) / sizeof(weights[0]); i < len; ++i) { | ||
| switch (i[weights]) { | ||
| case 1: // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 14] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 0, False: 1] | ||
| // fallthrough | ||
| case 2: // CHECK: Branch ([[@LINE]]:5): [True: 2, False: 13] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 2, False: 1] | ||
| break; | ||
| case 3: // CHECK: Branch ([[@LINE]]:5): [True: 3, False: 12] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 3, False: 0] | ||
| continue; | ||
| case 4: // CHECK: Branch ([[@LINE]]:5): [True: 4, False: 11] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 4, False: 0] | ||
| switch (i) { | ||
| case 6 ... 9: // CHECK: Branch ([[@LINE]]:7): [True: 4, False: 0] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:13): [True: 4, False: 0] | ||
| continue; | ||
| } | ||
|
|
||
| default: // CHECK: Branch ([[@LINE]]:5): [True: 5, False: 10] | ||
| if (i == len - 1) // CHECK: Branch ([[@LINE]]:11): [True: 1, False: 4] | ||
| return; | ||
| } | ||
| } | ||
|
|
||
| // Never reached -> no weights | ||
| if (weights[0]) {} // CHECK: Branch ([[@LINE]]:7): [True: 0, False: 0] | ||
|
|
||
| } | ||
|
|
||
| void big_switch() { | ||
| for (int i = 0; i < 32; ++i) {// CHECK: Branch ([[@LINE]]:19): [True: 32, False: 1] | ||
| switch (1 << i) { | ||
| case (1 << 0): // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 31] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 0, False: 1] | ||
| // fallthrough | ||
| case (1 << 1): // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 31] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 1, False: 1] | ||
| break; | ||
| case (1 << 2) ... (1 << 12):// CHECK: Branch ([[@LINE]]:5): [True: 11, False: 21] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 11, False: 0] | ||
| break; | ||
| // The branch for the large case range above appears after the case body. | ||
|
|
||
| case (1 << 13): // CHECK: Branch ([[@LINE]]:5): [True: 1, False: 31] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 1, False: 0] | ||
| break; | ||
| case (1 << 14) ... (1 << 28):// CHECK: Branch ([[@LINE]]:5): [True: 15, False: 17] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 15, False: 0] | ||
| break; | ||
| // The branch for the large case range above appears after the case body. | ||
| // CHECK: Branch ([[@LINE+1]]:5): [True: 1, False: 31] | ||
| case (1 << 29) ... ((1 << 29) + 1): | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 1, False: 0] | ||
| break; | ||
| default: // CHECK: Branch ([[@LINE]]:5): [True: 2, False: 30] | ||
| if (i) {} // CHECK: Branch ([[@LINE]]:11): [True: 2, False: 0] | ||
| break; | ||
| } | ||
| } | ||
|
|
||
| } | ||
|
|
||
| void boolean_operators() { | ||
| int v; // CHECK: Branch ([[@LINE+1]]:19): [True: 100, False: 1] | ||
| for (int i = 0; i < 100; ++i) { | ||
| v = i % 3 || i; // CHECK: Branch ([[@LINE]]:9): [True: 66, False: 34] | ||
| // CHECK: Branch ([[@LINE-1]]:18): [True: 33, False: 1] | ||
| v = i % 3 && i; // CHECK: Branch ([[@LINE]]:9): [True: 66, False: 34] | ||
| // CHECK: Branch ([[@LINE-1]]:18): [True: 66, False: 0] | ||
| v = i % 3 || i % 2 || i; // CHECK: Branch ([[@LINE]]:9): [True: 66, False: 34] | ||
| // CHECK: Branch ([[@LINE-1]]:18): [True: 17, False: 17] | ||
| v = i % 2 && i % 3 && i; // CHECK: Branch ([[@LINE-2]]:27): [True: 16, False: 1] | ||
| } // CHECK: Branch ([[@LINE-1]]:9): [True: 50, False: 50] | ||
| // CHECK: Branch ([[@LINE-2]]:18): [True: 33, False: 17] | ||
| } // CHECK: Branch ([[@LINE-3]]:27): [True: 33, False: 0] | ||
|
|
||
| void boolop_loops() { | ||
| int i = 100; | ||
|
|
||
| while (i && i > 50) // CHECK: Branch ([[@LINE]]:10): [True: 51, False: 0] | ||
| i--; // CHECK: Branch ([[@LINE-1]]:15): [True: 50, False: 1] | ||
|
|
||
| while ((i % 2) || (i > 0)) // CHECK: Branch ([[@LINE]]:10): [True: 25, False: 26] | ||
| i--; // CHECK: Branch ([[@LINE-1]]:21): [True: 25, False: 1] | ||
|
|
||
| for (i = 100; i && i > 50; --i); // CHECK: Branch ([[@LINE]]:17): [True: 51, False: 0] | ||
| // CHECK: Branch ([[@LINE-1]]:22): [True: 50, False: 1] | ||
| for (; (i % 2) || (i > 0); --i); // CHECK: Branch ([[@LINE]]:10): [True: 25, False: 26] | ||
| // CHECK: Branch ([[@LINE-1]]:21): [True: 25, False: 1] | ||
| } | ||
|
|
||
| void conditional_operator() { | ||
| int i = 100; | ||
|
|
||
| int j = i < 50 ? i : 1; // CHECK: Branch ([[@LINE]]:11): [True: 0, False: 1] | ||
|
|
||
| int k = i ?: 0; // CHECK: Branch ([[@LINE]]:11): [True: 1, False: 0] | ||
|
|
||
| } | ||
|
|
||
| void do_fallthrough() { | ||
| for (int i = 0; i < 10; ++i) {// CHECK: Branch ([[@LINE]]:19): [True: 10, False: 1] | ||
| int j = 0; | ||
| do { | ||
| // The number of exits out of this do-loop via the break statement | ||
| // exceeds the counter value for the loop (which does not include the | ||
| // fallthrough count). Make sure that does not violate any assertions. | ||
| if (i < 8) break; // CHECK: Branch ([[@LINE]]:11): [True: 8, False: 4] | ||
| j++; | ||
| } while (j < 2); // CHECK: Branch ([[@LINE]]:14): [True: 2, False: 2] | ||
| } | ||
| } | ||
|
|
||
| static void static_func() { | ||
| for (int i = 0; i < 10; ++i) {// CHECK: Branch ([[@LINE]]:19): [True: 10, False: 1] | ||
| } | ||
| } | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
| int main(int argc, const char *argv[]) { | ||
| simple_loops(); | ||
| conditionals(); | ||
| early_exits(); | ||
| jumps(); | ||
| switches(); | ||
| big_switch(); | ||
| boolean_operators(); | ||
| boolop_loops(); | ||
| conditional_operator(); | ||
| do_fallthrough(); | ||
| static_func(); | ||
| extern void __llvm_profile_write_file(); | ||
| __llvm_profile_write_file(); | ||
| return 0; | ||
| } | ||
|
|
||
| // REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: simple_loops 8 0 100.00% 9 0 100.00% 6 0 100.00% | ||
| // REPORT-NEXT: conditionals 24 0 100.00% 15 0 100.00% 16 2 87.50% | ||
| // REPORT-NEXT: early_exits 20 4 80.00% 25 3 88.00% 16 6 62.50% | ||
| // REPORT-NEXT: jumps 39 12 69.23% 48 4 91.67% 26 9 65.38% | ||
| // REPORT-NEXT: switches 28 5 82.14% 38 5 86.84% 30 9 70.00% | ||
| // REPORT-NEXT: big_switch 25 1 96.00% 32 0 100.00% 30 6 80.00% | ||
| // REPORT-NEXT: boolean_operators 16 0 100.00% 13 0 100.00% 22 2 90.91% | ||
| // REPORT-NEXT: boolop_loops 19 0 100.00% 14 0 100.00% 16 2 87.50% | ||
| // REPORT-NEXT: conditional_operator 4 2 50.00% 8 1 87.50% 4 2 50.00% | ||
| // REPORT-NEXT: do_fallthrough 9 0 100.00% 12 0 100.00% 6 0 100.00% | ||
| // REPORT-NEXT: main 1 0 100.00% 16 0 100.00% 0 0 0.00% | ||
| // REPORT-NEXT: c-general.c:static_func 4 0 100.00% 4 0 100.00% 2 0 100.00% | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: TOTAL 197 24 87.82% 234 13 94.44% 174 38 78.16% | ||
|
|
||
| // Test file-level report. | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata | ||
| // RUN: llvm-cov report %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=FILEREPORT | ||
| // FILEREPORT: TOTAL{{.*}}174 38 78.16% | ||
|
|
||
| // Test color True/False output. | ||
| // RUN: llvm-cov show --use-color --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=USECOLOR | ||
| // USECOLOR: Branch ({{[0-9]+}}:7): {{.*}}: 0, {{.*}}0] | ||
|
|
||
| // Test html output. | ||
| // RUN: llvm-cov show --show-branch-summary --show-branches=count %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s -format html -o %t.html.dir | ||
| // RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/tmp/branch-c-general.c.html %s | ||
| // HTML-COUNT-89: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span> | ||
| // HTML-NOT: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span> | ||
|
|
||
| // RUN: FileCheck -check-prefix HTML-INDEX -input-file %t.html.dir/index.html %s | ||
| // HTML-INDEX-LABEL: <table> | ||
| // HTML-INDEX: <td class='column-entry-bold'>Filename</td> | ||
| // HTML-INDEX: <td class='column-entry-bold'>Function Coverage</td> | ||
| // HTML-INDEX: <td class='column-entry-bold'>Line Coverage</td> | ||
| // HTML-INDEX: <td class='column-entry-bold'>Region Coverage</td> | ||
| // HTML-INDEX: <td class='column-entry-bold'>Branch Coverage</td> | ||
| // HTML-INDEX: <a href='coverage{{.*}}branch-c-general.c.html'{{.*}}branch-c-general.c</a> | ||
| // HTML-INDEX: <td class='column-entry-green'> | ||
| // HTML-INDEX: 100.00% (12/12) | ||
| // HTML-INDEX: <td class='column-entry-yellow'> | ||
| // HTML-INDEX: 94.44% (221/234) | ||
| // HTML-INDEX: <td class='column-entry-yellow'> | ||
| // HTML-INDEX: 87.82% (173/197) | ||
| // HTML-INDEX: <td class='column-entry-red'> | ||
| // HTML-INDEX: 78.16% (136/174) | ||
| // HTML-INDEX: <tr class='light-row-bold'> | ||
| // HTML-INDEX: Totals |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
|
|
||
| // RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata | ||
| // RUN: llvm-cov export --format=text %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %S/branch-showBranchPercentage.c | FileCheck %s | ||
|
|
||
| // CHECK: "branches": | ||
| // CHECK: 14,7,14,15,1,5,0,0,4 | ||
| // CHECK: 27,8,27,14,1,4,0,0,4 | ||
| // CHECK: 27,18,27,24,0,1,0,0,4 | ||
| // CHECK: 27,29,27,36,0,5,0,0,4 | ||
| // CHECK: 27,40,27,46,2,3,0,0,4 | ||
| // CHECK: 30,8,30,14,4,1,0,0,4 | ||
| // CHECK: 30,18,30,24,0,1,0,0,4 | ||
| // CHECK: 32,8,32,14,4,1,0,0,4 | ||
| // CHECK: 32,18,32,24,1,3,0,0,4 | ||
| // CHECK: 34,15,34,20,1,5,0,0,4 | ||
| // CHECK: 41,5,41,11,1,4,0,0,4 | ||
| // CHECK: 43,5,43,11,1,4,0,0,4 | ||
| // CHECK: 45,5,45,11,0,5,0,0,4 | ||
| // CHECK: 47,5,47,12,3,2,0,0,4 | ||
| // CHECK: 53,12,53,20,50,5,0,0,4 | ||
| // CHECK: {"count":30,"covered":26,"notcovered":4,"percent":86.666666666666671} | ||
|
|
||
| // Check recursive macro-expansions. | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata | ||
| // RUN: llvm-cov export --format=text %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %S/branch-macros.c | FileCheck %s -check-prefix=MACROS | ||
|
|
||
| // MACROS: "branches": | ||
| // MACROS: 27,10,27,11,0,3,0,0,4 | ||
| // MACROS: 27,15,27,16,0,0,0,0,4 | ||
| // MACROS: 27,20,27,21,0,0,0,0,4 | ||
| // MACROS: 27,25,27,26,0,0,0,0,4 | ||
| // MACROS: 27,30,27,31,0,0,0,0,4 | ||
|
|
||
| // MACROS: 15,5,23,1,2,1,0,4 | ||
| // MACROS: 6,15,6,23,0,1,2,0,4 | ||
| // MACROS: 5,15,5,23,1,2,7,0,4 | ||
| // MACROS: 6,15,6,23,0,1,8,0,4 | ||
| // MACROS: 5,15,5,23,1,2,12,0,4 | ||
| // MACROS: 6,15,6,23,0,1,13,0,4 | ||
| // MACROS: 5,15,5,23,1,2,16,0,4 | ||
| // MACROS: 6,15,6,23,0,1,17,0,4 | ||
| // MACROS: 5,15,5,23,1,2,19,0,4 | ||
| // MACROS: 6,15,6,23,0,1,20,0,4 | ||
| // MACROS: 5,15,5,23,1,2,11,0,4 | ||
| // MACROS: 6,15,6,23,0,1,12,0,4 | ||
| // MACROS: 5,15,5,23,1,2,8,0,4 | ||
| // MACROS: 6,15,6,23,0,1,9,0,4 | ||
| // MACROS: 8,15,8,38,1,2,2,0,4 | ||
| // MACROS: {"count":40,"covered":24,"notcovered":16,"percent":60} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,73 @@ | ||
|
|
||
| // RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata | ||
| // RUN: llvm-cov export --format=lcov %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %S/branch-showBranchPercentage.c | FileCheck %s | ||
|
|
||
| // CHECK-DAG: BRDA:14,0,0,1 | ||
| // CHECK-DAG: BRDA:14,0,1,5 | ||
| // CHECK-DAG: BRDA:27,0,0,1 | ||
| // CHECK-DAG: BRDA:27,0,1,4 | ||
| // CHECK-DAG: BRDA:27,1,2,0 | ||
| // CHECK-DAG: BRDA:27,1,3,1 | ||
| // CHECK-DAG: BRDA:27,2,4,0 | ||
| // CHECK-DAG: BRDA:27,2,5,5 | ||
| // CHECK-DAG: BRDA:27,3,6,2 | ||
| // CHECK-DAG: BRDA:27,3,7,3 | ||
| // CHECK-DAG: BRDA:30,0,0,4 | ||
| // CHECK-DAG: BRDA:30,0,1,1 | ||
| // CHECK-DAG: BRDA:30,1,2,0 | ||
| // CHECK-DAG: BRDA:30,1,3,1 | ||
| // CHECK-DAG: BRDA:32,0,0,4 | ||
| // CHECK-DAG: BRDA:32,0,1,1 | ||
| // CHECK-DAG: BRDA:32,1,2,1 | ||
| // CHECK-DAG: BRDA:32,1,3,3 | ||
| // CHECK-DAG: BRDA:34,0,0,1 | ||
| // CHECK-DAG: BRDA:34,0,1,5 | ||
| // CHECK-DAG: BRDA:41,0,0,1 | ||
| // CHECK-DAG: BRDA:41,0,1,4 | ||
| // CHECK-DAG: BRDA:43,0,0,1 | ||
| // CHECK-DAG: BRDA:43,0,1,4 | ||
| // CHECK-DAG: BRDA:45,0,0,0 | ||
| // CHECK-DAG: BRDA:45,0,1,5 | ||
| // CHECK-DAG: BRDA:47,0,0,3 | ||
| // CHECK-DAG: BRDA:47,0,1,2 | ||
| // CHECK-DAG: BRDA:53,0,0,50 | ||
| // CHECK-DAG: BRDA:53,0,1,5 | ||
| // CHECK-NOT: BRDA | ||
| // CHECK: BRF:30 | ||
| // CHECK: BFH:26 | ||
|
|
||
| // Check recursive macro-expansions. | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata | ||
| // RUN: llvm-cov export --format=lcov %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %S/branch-macros.cpp | FileCheck %s -check-prefix=MACROS | ||
|
|
||
| // MACROS-COUNT-4: BRDA:17 | ||
| // MACROS-NOT: BRDA:17 | ||
|
|
||
| // MACROS-COUNT-4: BRDA:19 | ||
| // MACROS-NOT: BRDA:19 | ||
|
|
||
| // MACROS-COUNT-4: BRDA:21 | ||
| // MACROS-NOT: BRDA:21 | ||
|
|
||
| // MACROS-COUNT-4: BRDA:23 | ||
| // MACROS-NOT: BRDA:23 | ||
|
|
||
| // MACROS-COUNT-4: BRDA:25 | ||
| // MACROS-NOT: BRDA:25 | ||
|
|
||
| // MACROS: BRDA:27,0,0,0 | ||
| // MACROS: BRDA:27,0,1,3 | ||
| // MACROS: BRDA:27,1,2,- | ||
| // MACROS: BRDA:27,1,3,- | ||
| // MACROS: BRDA:27,2,4,- | ||
| // MACROS: BRDA:27,2,5,- | ||
| // MACROS: BRDA:27,3,6,- | ||
| // MACROS: BRDA:27,3,7,- | ||
| // MACROS: BRDA:27,4,8,- | ||
| // MACROS: BRDA:27,4,9,- | ||
|
|
||
| // MACROS-COUNT-10: BRDA:37 | ||
| // MACROS-NOT: BRDA:37 | ||
| // MACROS-NOT: BRDA | ||
| // MACROS: BRF:40 | ||
| // MACROS: BFH:24 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,90 @@ | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-logical-mixed.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-branches=count %S/Inputs/branch-logical-mixed.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s | ||
| // RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-logical-mixed.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT | ||
|
|
||
| #include <stdio.h> | ||
| #include <stdlib.h> | ||
|
|
||
| void func(int a, int b) { | ||
| bool b0 = a <= b; | ||
| bool b1 = a == b; | ||
| bool b2 = a >= b; | ||
| bool b3 = a < b; | ||
| bool b4 = a > b; | ||
| bool b5 = a != b; | ||
|
|
||
| bool c = b0 && // CHECK: Branch ([[@LINE]]:12): [True: 3, False: 1] | ||
| b1 && // CHECK: Branch ([[@LINE]]:12): [True: 2, False: 1] | ||
| b2 && // CHECK: Branch ([[@LINE]]:12): [True: 2, False: 0] | ||
| b3 && // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 2] | ||
| b4 && // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 0] | ||
| b5; // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 0] | ||
|
|
||
| bool d = b0 || // CHECK: Branch ([[@LINE]]:12): [True: 3, False: 1] | ||
| b1 || // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 1] | ||
| b2 || // CHECK: Branch ([[@LINE]]:12): [True: 1, False: 0] | ||
| b3 || // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 0] | ||
| b4 || // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 0] | ||
| b5; // CHECK: Branch ([[@LINE]]:12): [True: 0, False: 0] | ||
|
|
||
| bool e = (b0 && // CHECK: Branch ([[@LINE]]:13): [True: 3, False: 1] | ||
| b5) || // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 2] | ||
| (b1 && // CHECK: Branch ([[@LINE]]:13): [True: 2, False: 1] | ||
| b4) || // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 2] | ||
| (b2 && // CHECK: Branch ([[@LINE]]:13): [True: 3, False: 0] | ||
| b3) || // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 3] | ||
| (b3 && // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 3] | ||
| b2) || // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 0] | ||
| (b4 && // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 2] | ||
| b1) || // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 1] | ||
| (b5 && // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 2] | ||
| b0); // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 1] | ||
|
|
||
| bool f = (b0 || // CHECK: Branch ([[@LINE]]:13): [True: 3, False: 1] | ||
| b5) && // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 0] | ||
| (b1 || // CHECK: Branch ([[@LINE]]:13): [True: 2, False: 2] | ||
| b4) && // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 1] | ||
| (b2 || // CHECK: Branch ([[@LINE]]:13): [True: 3, False: 0] | ||
| b3) && // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 0] | ||
| (b3 || // CHECK: Branch ([[@LINE]]:13): [True: 0, False: 3] | ||
| b2) && // CHECK: Branch ([[@LINE]]:13): [True: 3, False: 0] | ||
| (b4 || // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 2] | ||
| b1) && // CHECK: Branch ([[@LINE]]:13): [True: 2, False: 0] | ||
| (b5 || // CHECK: Branch ([[@LINE]]:13): [True: 1, False: 2] | ||
| b0); // CHECK: Branch ([[@LINE]]:13): [True: 2, False: 0] | ||
|
|
||
| if (c) // CHECK: Branch ([[@LINE]]:7): [True: 0, False: 4] | ||
| printf("case0\n"); | ||
| else | ||
| printf("case1\n"); | ||
|
|
||
| if (d) // CHECK: Branch ([[@LINE]]:7): [True: 4, False: 0] | ||
| printf("case2\n"); | ||
| else | ||
| printf("case3\n"); | ||
|
|
||
| if (e) // CHECK: Branch ([[@LINE]]:7): [True: 1, False: 3] | ||
| printf("case4\n"); | ||
| else | ||
| printf("case5\n"); | ||
|
|
||
| if (f) // CHECK: Branch ([[@LINE]]:7): [True: 3, False: 1] | ||
| printf("case6\n"); | ||
| else | ||
| printf("case7\n"); | ||
| } | ||
|
|
||
| extern "C" { extern void __llvm_profile_write_file(void); } | ||
| int main(int argc, char *argv[]) | ||
| { | ||
| func(atoi(argv[1]), atoi(argv[2])); | ||
| __llvm_profile_write_file(); | ||
| return 0; | ||
| } | ||
|
|
||
| // REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: _Z4funcii 77 9 88.31% 68 10 85.29% 80 32 60.00% | ||
| // REPORT-NEXT: main 1 0 100.00% 5 0 100.00% 0 0 0.00% | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: TOTAL 78 9 88.46% 73 10 86.30% 80 32 60.00% |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,60 @@ | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-macros.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-expansions --show-branches=count %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s | ||
| // RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-macros.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT | ||
|
|
||
| #define COND1 (a == b) | ||
| #define COND2 (a != b) | ||
| #define COND3 (COND1 && COND2) | ||
| #define COND4 (COND3 ? COND2 : COND1) | ||
| #define MACRO1 COND3 | ||
| #define MACRO2 MACRO1 | ||
| #define MACRO3 MACRO2 | ||
|
|
||
| #include <stdlib.h> | ||
|
|
||
|
|
||
| bool func(int a, int b) { | ||
| bool c = COND1 && COND2; // CHECK: | | | Branch ([[@LINE-12]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | Branch ([[@LINE-12]]:15): [True: 0, False: 1] | ||
| bool d = COND3; // CHECK: | | | | | Branch ([[@LINE-14]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | Branch ([[@LINE-14]]:15): [True: 0, False: 1] | ||
| bool e = MACRO1; // CHECK: | | | | | | | Branch ([[@LINE-16]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | | | Branch ([[@LINE-16]]:15): [True: 0, False: 1] | ||
| bool f = MACRO2; // CHECK: | | | | | | | | | Branch ([[@LINE-18]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | | | | | Branch ([[@LINE-18]]:15): [True: 0, False: 1] | ||
| bool g = MACRO3; // CHECK: | | | | | | | | | | | Branch ([[@LINE-20]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | | | | | | | Branch ([[@LINE-20]]:15): [True: 0, False: 1] | ||
| return c && d && e && f && g; | ||
| // CHECK: | Branch ([[@LINE-1]]:10): [True: 0, False: 3] | ||
| // CHECK: | Branch ([[@LINE-2]]:15): [True: 0, False: 0] | ||
| // CHECK: | Branch ([[@LINE-3]]:20): [True: 0, False: 0] | ||
| // CHECK: | Branch ([[@LINE-4]]:25): [True: 0, False: 0] | ||
| // CHECK: | Branch ([[@LINE-5]]:30): [True: 0, False: 0] | ||
| } | ||
|
|
||
|
|
||
| bool func2(int a, int b) { | ||
| bool h = MACRO3 || COND4; // CHECK: | | | | | | | | | | | Branch ([[@LINE-32]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | | | | | | | Branch ([[@LINE-32]]:15): [True: 0, False: 1] | ||
| // CHECK: | | | | | | | Branch ([[@LINE-34]]:15): [True: 1, False: 2] | ||
| // CHECK: | | | | | | | Branch ([[@LINE-34]]:15): [True: 0, False: 1] | ||
| // CHECK: | | | Branch ([[@LINE-33]]:15): [True: 1, False: 2] | ||
| return h; | ||
| } | ||
|
|
||
| extern "C" { extern void __llvm_profile_write_file(void); } | ||
| int main(int argc, char *argv[]) | ||
| { | ||
| func(atoi(argv[1]), atoi(argv[2])); | ||
| func2(atoi(argv[1]), atoi(argv[2])); | ||
| __llvm_profile_write_file(); | ||
| return 0; | ||
| } | ||
|
|
||
| // REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: _Z4funcii 28 4 85.71% 18 0 100.00% 30 14 53.33% | ||
| // REPORT-NEXT: _Z5func2ii 13 1 92.31% 8 0 100.00% 10 2 80.00% | ||
| // REPORT-NEXT: main 1 0 100.00% 6 0 100.00% 0 0 0.00% | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: TOTAL 42 5 88.10% 32 0 100.00% 40 16 60.00% |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
|
|
||
| // RUN: llvm-profdata merge %S/Inputs/branch-c-general.proftext -o %t.profdata | ||
| // RUN: llvm-cov show %S/Inputs/branch-c-general.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %S/branch-c-general.c | FileCheck %s | ||
| // RUN: llvm-cov report %S/Inputs/branch-c-general.o32l --show-branch-summary=false -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %S/branch-c-general.c | FileCheck %s -check-prefix=REPORT | ||
|
|
||
| // CHECK-NOT: | Branch | ||
|
|
||
| // REPORT: Name Regions Miss Cover Lines Miss Cover | ||
| // REPORT-NOT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover | ||
| // REPORT: --- | ||
| // REPORT-NOT: simple_loops 8 0 100.00% 9 0 100.00% 6 0 100.00% | ||
| // REPORT-NOT: conditionals 24 0 100.00% 15 0 100.00% 16 2 87.50% | ||
| // REPORT-NOT: early_exits 20 4 80.00% 25 2 92.00% 16 6 62.50% | ||
| // REPORT-NOT: jumps 39 12 69.23% 48 2 95.83% 26 9 65.38% | ||
| // REPORT-NOT: switches 28 5 82.14% 38 4 89.47% 30 9 70.00% | ||
| // REPORT-NOT: big_switch 25 1 96.00% 32 0 100.00% 30 6 80.00% | ||
| // REPORT-NOT: boolean_operators 16 0 100.00% 13 0 100.00% 22 2 90.91% | ||
| // REPORT-NOT: boolop_loops 19 0 100.00% 14 0 100.00% 16 2 87.50% | ||
| // REPORT-NOT: conditional_operator 4 2 50.00% 8 0 100.00% 4 2 50.00% | ||
| // REPORT-NOT: do_fallthrough 9 0 100.00% 12 0 100.00% 6 0 100.00% | ||
| // REPORT-NOT: main 1 0 100.00% 16 0 100.00% 0 0 0.00% | ||
| // REPORT-NOT: c-general.c:static_func 4 0 100.00% 4 0 100.00% 2 0 100.00% | ||
| // REPORT: TOTAL 197 24 87.82% 234 13 94.44% | ||
| // REPORT-NOT: TOTAL 197 24 87.82% 234 13 94.44% 174 38 78.16% | ||
|
|
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,77 @@ | ||
| // Test visualization of branch taken percentages | ||
|
|
||
| // RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-branches=percent %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s | ||
|
|
||
| #include <stdio.h> | ||
| #include <stdlib.h> | ||
|
|
||
| extern void __llvm_profile_write_file(void); | ||
|
|
||
| int main(int argc, char *argv[]) | ||
| { | ||
| int i = 0; | ||
| if (argc < 3) // CHECK: Branch ([[@LINE]]:7): [True: 16.67%, False: 83.33%] | ||
| { | ||
| __llvm_profile_write_file(); | ||
| return 0; | ||
| } | ||
|
|
||
| int a = atoi(argv[1]); | ||
| int b = atoi(argv[2]); | ||
|
|
||
| // CHECK: Branch ([[@LINE+4]]:8): [True: 20.00%, False: 80.00%] | ||
| // CHECK: Branch ([[@LINE+3]]:18): [True: 0.00%, False: 100.00%] | ||
| // CHECK: Branch ([[@LINE+2]]:29): [True: 0.00%, False: 100.00%] | ||
| // CHECK: Branch ([[@LINE+1]]:40): [True: 40.00%, False: 60.00%] | ||
| if ((a == 0 && b == 2) || b == 34 || a == b) | ||
| printf("case1\n"); | ||
|
|
||
| b = (a != 0 || a == 2) ? b : b+2; // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%] | ||
| // CHECK: Branch ([[@LINE-1]]:18): [True: 0.00%, False: 100.00%] | ||
| b = (a != 0 && a == 1); // CHECK: Branch ([[@LINE]]:8): [True: 80.00%, False: 20.00%] | ||
| // CHECK: Branch ([[@LINE-1]]:18): [True: 25.00%, False: 75.00%] | ||
| for (i = 0; i < b; i++) { a = 2 + b + b; } | ||
| // CHECK: Branch ([[@LINE-1]]:15): [True: 16.67%, False: 83.33%] | ||
|
|
||
| b = a; | ||
|
|
||
| switch (a) | ||
| { | ||
| case 0: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%] | ||
| printf("case0\n"); | ||
| case 2: // CHECK: Branch ([[@LINE]]:5): [True: 20.00%, False: 80.00%] | ||
| printf("case2\n"); | ||
| case 3: // CHECK: Branch ([[@LINE]]:5): [True: 0.00%, False: 100.00%] | ||
| printf("case3\n"); | ||
| default: break; // CHECK: Branch ([[@LINE]]:5): [True: 60.00%, False: 40.00%] | ||
| } | ||
|
|
||
| i = 0; | ||
| do { | ||
| printf("loop\n"); | ||
| } while (i++ < 10); // CHECK: Branch ([[@LINE]]:12): [True: 90.91%, False: 9.09%] | ||
|
|
||
| __llvm_profile_write_file(); | ||
|
|
||
| return b; | ||
| } | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-showBranchPercentage.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-branches=percent %S/Inputs/branch-showBranchPercentage.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s -format html -o %t.html.dir | ||
|
|
||
| // Test html output. | ||
| // RUN: FileCheck -check-prefix=HTML -input-file=%t.html.dir/coverage/tmp/branch-showBranchPercentage.c.html %s | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}40.00%,{{.*}}60.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}80.00%,{{.*}}20.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}25.00%,{{.*}}75.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}16.67%,{{.*}}83.33%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}20.00%,{{.*}}80.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}0.00%,{{.*}}100.00%] | ||
| // HTML: Branch (<span class='line-number'><a name='L{{[0-9]+}}' href='#L{{[0-9]+}}'><span>{{.*}}60.00%,{{.*}}40.00%] |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| // RUN: llvm-profdata merge %S/Inputs/branch-templates.proftext -o %t.profdata | ||
| // RUN: llvm-cov show --show-expansions --show-branches=count %S/Inputs/branch-templates.o32l -instr-profile %t.profdata -path-equivalence=/tmp,%S %s | FileCheck %s | ||
| // RUN: llvm-cov report --show-branch-summary %S/Inputs/branch-templates.o32l -instr-profile %t.profdata -show-functions -path-equivalence=/tmp,%S %s | FileCheck %s -check-prefix=REPORT | ||
|
|
||
| #include <stdio.h> | ||
|
|
||
| template<typename T> | ||
| void unused(T x) { | ||
| return; | ||
| } | ||
|
|
||
| template<typename T> | ||
| int func(T x) { | ||
| if(x) // CHECK: | Branch ([[@LINE]]:6): [True: 0, False: 1] | ||
| return 0; // CHECK: | Branch ([[@LINE-1]]:6): [True: 1, False: 0] | ||
| else // CHECK: | Branch ([[@LINE-2]]:6): [True: 0, False: 1] | ||
| return 1; | ||
| int j = 1; | ||
| } | ||
|
|
||
| // CHECK-LABEL: _Z4funcIiEiT_: | ||
| // CHECK: | | Branch ([[@LINE-8]]:6): [True: 0, False: 1] | ||
| // CHECK-LABEL: _Z4funcIbEiT_: | ||
| // CHECK: | | Branch ([[@LINE-10]]:6): [True: 1, False: 0] | ||
| // CHECK-LABEL: _Z4funcIfEiT_: | ||
| // CHECK: | | Branch ([[@LINE-12]]:6): [True: 0, False: 1] | ||
|
|
||
| extern "C" { extern void __llvm_profile_write_file(void); } | ||
| int main() { | ||
| if (func<int>(0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0] | ||
| printf("case1\n"); | ||
| if (func<bool>(true)) // CHECK: | Branch ([[@LINE]]:7): [True: 0, False: 1] | ||
| printf("case2\n"); | ||
| if (func<float>(0.0)) // CHECK: | Branch ([[@LINE]]:7): [True: 1, False: 0] | ||
| printf("case3\n"); | ||
| __llvm_profile_write_file(); | ||
| return 0; | ||
| } | ||
|
|
||
| // REPORT: Name Regions Miss Cover Lines Miss Cover Branches Miss Cover | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: main 7 1 85.71% 10 1 90.00% 6 3 50.00% | ||
| // REPORT-NEXT: _Z4funcIiEiT_ 5 2 60.00% 7 3 57.14% 2 1 50.00% | ||
| // REPORT-NEXT: _Z4funcIbEiT_ 5 2 60.00% 7 4 42.86% 2 1 50.00% | ||
| // REPORT-NEXT: _Z4funcIfEiT_ 5 2 60.00% 7 3 57.14% 2 1 50.00% | ||
| // REPORT-NEXT: --- | ||
| // REPORT-NEXT: TOTAL 22 7 68.18% 31 11 64.52% 12 6 50.00% |