summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
diff options
context:
space:
mode:
authorDaniel Jasper <djasper@google.com>2014-02-19 12:26:01 +0000
committerDaniel Jasper <djasper@google.com>2014-02-19 12:26:01 +0000
commit7e198ad862cddf373edcb51801a9800c4637d52e (patch)
tree7a97a155d36e3ccc331ec56d3e18a7eefae5c408 /llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
parentd495642c5410f11345c03fcaa35fd346ad9ab207 (diff)
downloadbcm5719-llvm-7e198ad862cddf373edcb51801a9800c4637d52e.tar.gz
bcm5719-llvm-7e198ad862cddf373edcb51801a9800c4637d52e.zip
Revert r201622 and r201608.
This causes the LLVMgold plugin to segfault. More information on the replies to r201608. llvm-svn: 201669
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp15
1 files changed, 4 insertions, 11 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
index 6c4cddc3f6e..63b4bb4296c 100644
--- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
@@ -311,13 +311,8 @@ void AsmPrinter::EmitLinkage(const GlobalValue *GV, MCSymbol *GVSym) const {
llvm_unreachable("Unknown linkage type!");
}
-void AsmPrinter::getNameWithPrefix(SmallVectorImpl<char> &Name,
- const GlobalValue *GV) const {
- TM.getTargetLowering()->getNameWithPrefix(Name, GV, *Mang);
-}
-
MCSymbol *AsmPrinter::getSymbol(const GlobalValue *GV) const {
- return TM.getTargetLowering()->getSymbol(GV, *Mang);
+ return getObjFileLowering().getSymbol(GV, *Mang);
}
/// EmitGlobalVariable - Emit the specified global variable to the .s file.
@@ -1374,7 +1369,7 @@ void AsmPrinter::EmitLLVMUsedList(const ConstantArray *InitList) {
for (unsigned i = 0, e = InitList->getNumOperands(); i != e; ++i) {
const GlobalValue *GV =
dyn_cast<GlobalValue>(InitList->getOperand(i)->stripPointerCasts());
- if (GV && getObjFileLowering().shouldEmitUsedDirectiveFor(GV, *Mang, TM))
+ if (GV && getObjFileLowering().shouldEmitUsedDirectiveFor(GV, *Mang))
OutStreamer.EmitSymbolAttribute(getSymbol(GV), MCSA_NoDeadStrip);
}
}
@@ -1579,8 +1574,7 @@ static const MCExpr *lowerConstant(const Constant *CV, AsmPrinter &AP) {
}
if (const MCExpr *RelocExpr =
- AP.getObjFileLowering().getExecutableRelativeSymbol(CE, *AP.Mang,
- AP.TM))
+ AP.getObjFileLowering().getExecutableRelativeSymbol(CE, *AP.Mang))
return RelocExpr;
switch (CE->getOpcode()) {
@@ -2109,8 +2103,7 @@ MCSymbol *AsmPrinter::GetJTSetSymbol(unsigned UID, unsigned MBBID) const {
MCSymbol *AsmPrinter::getSymbolWithGlobalValueBase(const GlobalValue *GV,
StringRef Suffix) const {
- return getObjFileLowering().getSymbolWithGlobalValueBase(GV, Suffix, *Mang,
- TM);
+ return getObjFileLowering().getSymbolWithGlobalValueBase(GV, Suffix, *Mang);
}
/// GetExternalSymbolSymbol - Return the MCSymbol for the specified
OpenPOWER on IntegriCloud