summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@gmail.com>2016-09-20 22:03:28 +0000
committerEric Christopher <echristo@gmail.com>2016-09-20 22:03:28 +0000
commitc4636b30020d6a92c26c67af3f4ce30b28aefeeb (patch)
treeec7271759ed0fd6798a830897876eb2743d41333 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
parentea625ea01e200e4fac837d01e8abef665e3c8801 (diff)
downloadbcm5719-llvm-c4636b30020d6a92c26c67af3f4ce30b28aefeeb.tar.gz
bcm5719-llvm-c4636b30020d6a92c26c67af3f4ce30b28aefeeb.zip
Revert "Remove extra argument used once on
TargetMachine::getNameWithPrefix and inline the result into the singular caller." and "Remove more guts of TargetMachine::getNameWithPrefix and migrate one check to the TLOF mach-o version." temporarily until I can get the whole call migrated out of the TargetMachine as we could hit places where TLOF isn't valid. This reverts commits r281981 and r281983. llvm-svn: 282028
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
-rw-r--r--llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp b/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
index b8339eefd9c..edaa778a605 100644
--- a/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
+++ b/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
@@ -301,7 +301,7 @@ selectELFSectionForGlobal(MCContext &Ctx, const GlobalValue *GV,
if (EmitUniqueSection && UniqueSectionNames) {
Name.push_back('.');
- Mang.getNameWithPrefix(Name, GV, false);
+ TM.getNameWithPrefix(Name, GV, Mang, true);
}
unsigned UniqueID = MCContext::GenericSectionID;
if (EmitUniqueSection && !UniqueSectionNames) {
@@ -817,13 +817,6 @@ static bool canUsePrivateLabel(const MCAsmInfo &AsmInfo,
void TargetLoweringObjectFileMachO::getNameWithPrefix(
SmallVectorImpl<char> &OutName, const GlobalValue *GV,
const TargetMachine &TM) const {
- if (!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.
- getMangler().getNameWithPrefix(OutName, GV, false);
- return;
- }
-
SectionKind GVKind = TargetLoweringObjectFile::getKindForGlobal(GV, TM);
const MCSection *TheSection = SectionForGlobal(GV, GVKind, TM);
bool CannotUsePrivateLabel =
OpenPOWER on IntegriCloud