private:
virtual void initSectionLayout() override {
- SectionLayout = {{SecProfSummary},
- {SecNameTable},
- {SecLBRProfile},
- {SecProfileSymbolList}};
+ SectionLayout = {{SecProfSummary, 0, 0, 0},
+ {SecNameTable, 0, 0, 0},
+ {SecLBRProfile, 0, 0, 0},
+ {SecProfileSymbolList, 0, 0, 0}};
};
virtual std::error_code
writeSections(const StringMap<FunctionSamples> &ProfileMap) override;
StringRef CompressedStrings(reinterpret_cast<const char *>(Data),
*CompressSize);
char *Buffer = Allocator.Allocate<char>(DecompressBufSize);
+ size_t UCSize = DecompressBufSize;
llvm::Error E =
- zlib::uncompress(CompressedStrings, Buffer, DecompressBufSize);
+ zlib::uncompress(CompressedStrings, Buffer, UCSize);
if (E)
return sampleprof_error::uncompress_failed;
DecompressBuf = reinterpret_cast<const uint8_t *>(Buffer);