[PGO] Ensure vp data in indexed profile always sorted
authorXinliang David Li <davidxl@google.com>
Fri, 8 Jan 2016 05:45:21 +0000 (05:45 +0000)
committerXinliang David Li <davidxl@google.com>
Fri, 8 Jan 2016 05:45:21 +0000 (05:45 +0000)
commit36838feb749d1a0e874d1acc6f6bef9d05cfdbde
tree7ebaeb91e6e6f7f01c504992e14b355414af484e
parenta94cb08fdaecba77dea3b23dd9932a0c2caffda8
[PGO] Ensure vp data in indexed profile always sorted

Done in  InstrProfWriter to eliminate the need for client
code to do the sorting. The operation is done once and reused
many times so it is more efficient. Update unit test to remove
sorting. Also update expected output of affected tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@257145 91177308-0d34-0410-b5e6-96231b3b80d8
lib/ProfileData/InstrProfWriter.cpp
test/tools/llvm-profdata/value-prof.proftext
unittests/ProfileData/InstrProfTest.cpp