llvm.org GIT mirror llvm / 7aa6beb
Merging r232443: ------------------------------------------------------------------------ r232443 | mail | 2015-03-16 20:18:51 -0400 (Mon, 16 Mar 2015) | 4 lines llvm-cov: Warn instead of error if a .gcda has arcs from an exit block Patch by Vanderson M. Rosario. Thanks! ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_36@236304 91177308-0d34-0410-b5e6-96231b3b80d8 Tom Stellard 4 years ago
4 changed file(s) with 7 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
262262 // required to combine the edge counts that are contained in the GCDA file.
263263 for (uint32_t BlockNo = 0; Count > 0; ++BlockNo) {
264264 // The last block is always reserved for exit block
265 if (BlockNo >= Blocks.size()-1) {
265 if (BlockNo >= Blocks.size()) {
266266 errs() << "Unexpected number of edges (in " << Name << ").\n";
267267 return false;
268268 }
269 if (BlockNo == Blocks.size() - 1)
270 errs() << "(" << Name << ") has arcs from exit block.\n";
269271 GCOVBlock &Block = *Blocks[BlockNo];
270272 for (size_t EdgeNo = 0, End = Block.getNumDstEdges(); EdgeNo < End;
271273 ++EdgeNo) {
109109 # Bad function checksum on gcda
110110 RUN: llvm-cov test.c -gcda=test_func_checksum_fail.gcda
111111
112 # Has arcs from exit blocks
113 RUN: llvm-cov test_exit_block_arcs.c 2>&1 | FileCheck %s -check-prefix=EXIT_BLOCK_ARCS
114 EXIT_BLOCK_ARCS: (main) has arcs from exit block.
115
112116 XFAIL: powerpc64-, s390x, mips-, mips64-, sparc