[PATCH] D15100: [PGO] Add support for reading multiple versions of indexed profile format profile data

David Li via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 30 22:21:34 PST 2015


davidxl created this revision.
davidxl added a reviewer: vsk.
davidxl added a subscriber: llvm-commits.

LLVM profile reader for indexed format is intended to be backward compatible -- a new version of compiler producing different format of indexed profile data should be able to read old version of indexed profile data produced by older versions of compilers.  However currently it is  hard to read different versions of profile data with different key types with the current reader implementation.

This patch solves the problem. To read a particular version of indexed profile is will be as simple as instantiating the index template class with the OnDiskHashTable implementation type associated with that version. There will be a follow up patch to templatize the InstrProfLookupTrait class (for different key types associated with the format).

http://reviews.llvm.org/D15100

Files:
  include/llvm/ProfileData/InstrProfReader.h
  include/llvm/Support/OnDiskHashTable.h
  lib/ProfileData/InstrProfReader.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15100.41460.patch
Type: text/x-patch
Size: 9523 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151201/929ab5bf/attachment.bin>


More information about the llvm-commits mailing list