mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-13 17:00:01 +00:00
Global label not handled correctly.
llvm-svn: 31883
This commit is contained in:
parent
ad5f088196
commit
cd74ba8ae1
@ -334,9 +334,17 @@ void AsmPrinter::EmitXXStructorList(Constant *List) {
|
||||
/// generate the appropriate value.
|
||||
const std::string AsmPrinter::getGlobalLinkName(const GlobalVariable *GV) const{
|
||||
std::string LinkName;
|
||||
// Default action is to use a global symbol.
|
||||
LinkName = TAI->getGlobalPrefix();
|
||||
LinkName += GV->getName();
|
||||
|
||||
if (isa<Function>(GV)) {
|
||||
LinkName += TAI->getFunctionAddrPrefix();
|
||||
LinkName += Mang->getValueName(GV);
|
||||
LinkName += TAI->getFunctionAddrSuffix();
|
||||
} else {
|
||||
LinkName += TAI->getGlobalVarAddrPrefix();
|
||||
LinkName += Mang->getValueName(GV);
|
||||
LinkName += TAI->getGlobalVarAddrSuffix();
|
||||
}
|
||||
|
||||
return LinkName;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user