SamplePGO - Add coverage tracking for samples.
authorDiego Novillo <dnovillo@google.com>
Mon, 23 Nov 2015 20:12:21 +0000 (20:12 +0000)
committerDiego Novillo <dnovillo@google.com>
Mon, 23 Nov 2015 20:12:21 +0000 (20:12 +0000)
commitdf79221070e72b2fc5e01dccaa5875602d7073d2
treec0b79df26dc44f7ceed90b1d5dc0daa9543d1911
parent704489d52e8a2e9f62b478b8a3d3612bfe03bfc5
SamplePGO - Add coverage tracking for samples.

The existing coverage tracker counts the number of records that were used
from the input profile. An alternative view of coverage is to check how
many available samples were applied.

This way, if the profile contains several records with few samples, it
doesn't really matter much that they were not applied. The more
interesting records to apply are the ones that contribute many samples.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@253912 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/IPO/SampleProfile.cpp
test/Transforms/SampleProfile/cov-zero-samples.ll
test/Transforms/SampleProfile/coverage-warning.ll
test/Transforms/SampleProfile/inline-coverage.ll