[llvm-branch-commits] [llvm] [BOLT][NFC] Refactor function matching (PR #97502)
Shaw Young via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Jul 3 10:39:48 PDT 2024
================
@@ -456,6 +435,39 @@ Error YAMLProfileReader::readProfile(BinaryContext &BC) {
++MatchedWithLTOCommonName;
}
}
+ return MatchedWithLTOCommonName;
+}
+
+Error YAMLProfileReader::readProfile(BinaryContext &BC) {
+ if (opts::Verbosity >= 1) {
+ outs() << "BOLT-INFO: YAML profile with hash: ";
+ switch (YamlBP.Header.HashFunction) {
+ case HashFunction::StdHash:
+ outs() << "std::hash\n";
----------------
shawbyoung wrote:
I'm erring on the side of making minimal code change - although it's showing up on gh as code added, I haven't touched the prologue of readProfile. If you see the large "deleted" section above (starting on the original line 353 of YAMLProfileReader.cpp) it's the exact same. So, I'd like to keep this PR just about refactoring function matching.
https://github.com/llvm/llvm-project/pull/97502
More information about the llvm-branch-commits
mailing list