summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
566a7b0)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@255680
91177308-0d34-0410-b5e6-
96231b3b80d8
}
ValueProfData *allocValueProfDataInstrProf(size_t TotalSizeInBytes) {
}
ValueProfData *allocValueProfDataInstrProf(size_t TotalSizeInBytes) {
- return (ValueProfData *)(new (::operator new(TotalSizeInBytes))
- ValueProfData());
+ ValueProfData *VD =
+ (ValueProfData *)(new (::operator new(TotalSizeInBytes)) ValueProfData());
+ memset(VD, 0, TotalSizeInBytes);
+ return VD;
}
static ValueProfRecordClosure InstrProfRecordClosure = {
}
static ValueProfRecordClosure InstrProfRecordClosure = {
getNumValueDataForSiteInstrProf,
stringToHash,
getValueForSiteInstrProf,
getNumValueDataForSiteInstrProf,
stringToHash,
getValueForSiteInstrProf,
- allocValueProfDataInstrProf
-};
+ allocValueProfDataInstrProf};
// Wrapper implementation using the closure mechanism.
uint32_t ValueProfData::getSize(const InstrProfRecord &Record) {
// Wrapper implementation using the closure mechanism.
uint32_t ValueProfData::getSize(const InstrProfRecord &Record) {