diff options
| author | Eric Christopher <echristo@gmail.com> | 2016-10-14 05:47:41 +0000 |
|---|---|---|
| committer | Eric Christopher <echristo@gmail.com> | 2016-10-14 05:47:41 +0000 |
| commit | 2bd52b5d91f7f560f86eb60a7852e5c2f44aefa3 (patch) | |
| tree | 502348d7869485a76f4dcf7f47a75b72c62547d5 /llvm/lib/Target | |
| parent | 445c952bd0a3b35244476ba7ef9ff44b5483dfea (diff) | |
| download | bcm5719-llvm-2bd52b5d91f7f560f86eb60a7852e5c2f44aefa3.tar.gz bcm5719-llvm-2bd52b5d91f7f560f86eb60a7852e5c2f44aefa3.zip | |
In preparation for removing getNameWithPrefix off of TargetMachine,
sink the current behavior into the callers and sink
TargetMachine::getNameWithPrefix into TargetMachine::getSymbol.
llvm-svn: 284203
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/TargetMachine.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/llvm/lib/Target/TargetMachine.cpp b/llvm/lib/Target/TargetMachine.cpp index 792280af84d..28c9f370fb5 100644 --- a/llvm/lib/Target/TargetMachine.cpp +++ b/llvm/lib/Target/TargetMachine.cpp @@ -203,19 +203,13 @@ TargetIRAnalysis TargetMachine::getTargetIRAnalysis() { void TargetMachine::getNameWithPrefix(SmallVectorImpl<char> &Name, const GlobalValue *GV, Mangler &Mang, bool MayAlwaysUsePrivate) const { - if (MayAlwaysUsePrivate || !GV->hasPrivateLinkage()) { - // Simple case: If GV is not private, it is not important to find out if - // private labels are legal in this case or not. - Mang.getNameWithPrefix(Name, GV, false); - return; - } const TargetLoweringObjectFile *TLOF = getObjFileLowering(); TLOF->getNameWithPrefix(Name, GV, *this); } MCSymbol *TargetMachine::getSymbol(const GlobalValue *GV, Mangler &Mang) const { SmallString<128> NameStr; - getNameWithPrefix(NameStr, GV, Mang); const TargetLoweringObjectFile *TLOF = getObjFileLowering(); + TLOF->getNameWithPrefix(NameStr, GV, *this); return TLOF->getContext().getOrCreateSymbol(NameStr); } |

