Skip to content

Commit 4532512

Browse files
authored
[ctxprof] Move MoveSymbolGUID to address dependency issues (#134334)
See PR #134192
1 parent 2146826 commit 4532512

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

llvm/lib/Transforms/IPO/FunctionImport.cpp

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -182,14 +182,7 @@ static cl::opt<bool> CtxprofMoveRootsToOwnModule(
182182
"their own module."),
183183
cl::Hidden, cl::init(false));
184184

185-
cl::list<GlobalValue::GUID> MoveSymbolGUID(
186-
"thinlto-move-symbols",
187-
cl::desc(
188-
"Move the symbols with the given name. This will delete these symbols "
189-
"wherever they are originally defined, and make sure their "
190-
"linkage is External where they are imported. It is meant to be "
191-
"used with the name of contextual profiling roots."),
192-
cl::Hidden);
185+
extern cl::list<GlobalValue::GUID> MoveSymbolGUID;
193186

194187
namespace llvm {
195188
extern cl::opt<bool> EnableMemProfContextDisambiguation;

llvm/lib/Transforms/Utils/FunctionImportUtils.cpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,14 @@ static cl::opt<bool> UseSourceFilenameForPromotedLocals(
2424
"This requires that the source filename has a unique name / "
2525
"path to avoid name collisions."));
2626

27-
extern cl::list<GlobalValue::GUID> MoveSymbolGUID;
27+
cl::list<GlobalValue::GUID> MoveSymbolGUID(
28+
"thinlto-move-symbols",
29+
cl::desc(
30+
"Move the symbols with the given name. This will delete these symbols "
31+
"wherever they are originally defined, and make sure their "
32+
"linkage is External where they are imported. It is meant to be "
33+
"used with the name of contextual profiling roots."),
34+
cl::Hidden);
2835

2936
FunctionImportGlobalProcessing::FunctionImportGlobalProcessing(
3037
Module &M, const ModuleSummaryIndex &Index,

0 commit comments

Comments
 (0)