Move two Value Profiler data structs to InstrProfData.inc (NFC)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@253848 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Xinliang David Li 2015-11-23 05:29:51 +00:00
parent 94e1578270
commit 9c157b23d4
2 changed files with 19 additions and 7 deletions

View File

@ -199,13 +199,6 @@ struct InstrProfStringTable {
} }
}; };
struct InstrProfValueData {
// Profiled value.
uint64_t Value;
// Number of times the value appears in the training run.
uint64_t Count;
};
struct InstrProfValueSiteRecord { struct InstrProfValueSiteRecord {
/// Value profiling data pairs at a given value site. /// Value profiling data pairs at a given value site.
std::list<InstrProfValueData> ValueData; std::list<InstrProfValueData> ValueData;

View File

@ -230,6 +230,25 @@ COVMAP_FUNC_RECORD(const uint64_t, llvm::Type::getInt64Ty(Ctx), FuncHash, \
#define INSTR_PROF_VALUE_PROF_FUNC_STR \ #define INSTR_PROF_VALUE_PROF_FUNC_STR \
INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_FUNC) INSTR_PROF_QUOTE(INSTR_PROF_VALUE_PROF_FUNC)
/* The data structure that represents a tracked value by the
* value profiler.
*/
typedef struct InstrProfValueData {
// Profiled value.
uint64_t Value;
// Number of times the value appears in the training run.
uint64_t Count;
} InstrProfValueData;
/* This is an internal data structure used by value profiler. It
* is defined here to allow serialization code sharing by LLVM
* to be used in unit test.
*/
typedef struct ValueProfNode {
InstrProfValueData VData;
struct ValueProfNode *Next;
} ValueProfNode;
#endif /* INSTR_PROF_DATA_INC_ */ #endif /* INSTR_PROF_DATA_INC_ */
#else #else