MemoryBuffer *Buffer,
sampleprof::ProfileSymbolList &WriterList,
bool CompressAllSections, bool UseMD5,
- bool PartialProfile) {
+ bool GenPartialProfile) {
populateProfileSymbolList(Buffer, WriterList);
if (WriterList.size() > 0 && OutputFormat != PF_Ext_Binary)
warn("Profile Symbol list is not empty but the output format is not "
else
Writer.setUseMD5();
}
- if (PartialProfile) {
+ if (GenPartialProfile) {
if (OutputFormat != PF_Ext_Binary)
- warn("-partial-profile is ignored. Specify -extbinary to enable it");
+ warn("-gen-partial-profile is ignored. Specify -extbinary to enable it");
else
Writer.setPartialProfile();
}
mergeSampleProfile(const WeightedFileVector &Inputs, SymbolRemapper *Remapper,
StringRef OutputFilename, ProfileFormat OutputFormat,
StringRef ProfileSymbolListFile, bool CompressAllSections,
- bool UseMD5, bool PartialProfile, FailureMode FailMode) {
+ bool UseMD5, bool GenPartialProfile, FailureMode FailMode) {
using namespace sampleprof;
StringMap<FunctionSamples> ProfileMap;
SmallVector<std::unique_ptr<sampleprof::SampleProfileReader>, 5> Readers;
// Make sure Buffer lives as long as WriterList.
auto Buffer = getInputFileBuf(ProfileSymbolListFile);
handleExtBinaryWriter(*Writer, OutputFormat, Buffer.get(), WriterList,
- CompressAllSections, UseMD5, PartialProfile);
+ CompressAllSections, UseMD5, GenPartialProfile);
Writer->write(ProfileMap);
}
"use-md5", cl::init(false), cl::Hidden,
cl::desc("Choose to use MD5 to represent string in name table (only "
"meaningful for -extbinary)"));
- cl::opt<bool> PartialProfile(
- "partial-profile", cl::init(false), cl::Hidden,
- cl::desc("Set the profile to be a partial profile (only meaningful "
- "for -extbinary)"));
+ cl::opt<bool> GenPartialProfile(
+ "gen-partial-profile", cl::init(false), cl::Hidden,
+ cl::desc("Generate a partial profile (only meaningful for -extbinary)"));
cl::ParseCommandLineOptions(argc, argv, "LLVM profile data merger\n");
else
mergeSampleProfile(WeightedInputs, Remapper.get(), OutputFilename,
OutputFormat, ProfileSymbolListFile, CompressAllSections,
- UseMD5, PartialProfile, FailureMode);
+ UseMD5, GenPartialProfile, FailureMode);
return 0;
}