[llvm] [StaticDataLayout] Temporarily undo diagnostic warning when the data access profile payload is not available (PR #177412)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 22 09:52:15 PST 2026
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-llvm-transforms
Author: Mingming Liu (mingmingl-llvm)
<details>
<summary>Changes</summary>
Added a FIXME to add it back later after figuring out how to make it a non-error like the PGO profile mismatch one.
---
Full diff: https://github.com/llvm/llvm-project/pull/177412.diff
2 Files Affected:
- (modified) llvm/lib/ProfileData/MemProfSummary.cpp (+3-3)
- (modified) llvm/lib/Transforms/Instrumentation/MemProfUse.cpp (+2-5)
``````````diff
diff --git a/llvm/lib/ProfileData/MemProfSummary.cpp b/llvm/lib/ProfileData/MemProfSummary.cpp
index 1690745debf54..cec9ef5a57b1a 100644
--- a/llvm/lib/ProfileData/MemProfSummary.cpp
+++ b/llvm/lib/ProfileData/MemProfSummary.cpp
@@ -26,10 +26,10 @@ void MemProfSummary::printSummaryYaml(raw_ostream &OS) const {
OS << "# Maximum warm context total size: " << MaxWarmTotalSize << "\n";
OS << "# Maximum hot context total size: " << MaxHotTotalSize << "\n";
if (HasDataAccessProfile) {
- OS << "# Num hot symbols and string literals: "
+ OS << "# Num hot symbols and string literals: "
<< NumHotSymbolsAndStringLiterals << "\n";
- OS << "# Num known cold symbols: " << NumKnownColdSymbols << "\n";
- OS << "# Num known cold string literals: " << NumKnownColdStringLiterals
+ OS << "# Num known cold symbols: " << NumKnownColdSymbols << "\n";
+ OS << "# Num known cold string literals: " << NumKnownColdStringLiterals
<< "\n";
}
}
diff --git a/llvm/lib/Transforms/Instrumentation/MemProfUse.cpp b/llvm/lib/Transforms/Instrumentation/MemProfUse.cpp
index 1a55021c5d3f7..748c4cb711027 100644
--- a/llvm/lib/Transforms/Instrumentation/MemProfUse.cpp
+++ b/llvm/lib/Transforms/Instrumentation/MemProfUse.cpp
@@ -910,11 +910,8 @@ bool MemProfUsePass::annotateGlobalVariables(
if (!DataAccessProf) {
M.addModuleFlag(Module::Warning, "EnableDataAccessProf", 0U);
- M.getContext().diagnose(DiagnosticInfoPGOProfile(
- MemoryProfileFileName.data(),
- StringRef("Data access profiles not found in memprof. Ignore "
- "-memprof-annotate-static-data-prefix."),
- DS_Warning));
+ // FIXME: Add a diagnostic message without failing the compilation when
+ // data access profile payload is not available.
return false;
}
M.addModuleFlag(Module::Warning, "EnableDataAccessProf", 1U);
``````````
</details>
https://github.com/llvm/llvm-project/pull/177412
More information about the llvm-commits
mailing list