mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01:00
Start using PrivateGlobalPrefix correctly
llvm-svn: 24442
This commit is contained in:
parent
78bb97af59
commit
07ea769304
@ -43,6 +43,7 @@ namespace {
|
||||
: AsmPrinter(o, tm), LabelNumber(0)
|
||||
{
|
||||
AlignmentIsInBytes = false;
|
||||
PrivateGlobalPrefix = "$";
|
||||
}
|
||||
|
||||
/// We name each basic block in a Function with a unique number, so
|
||||
@ -131,7 +132,8 @@ void AlphaAsmPrinter::printOp(const MachineOperand &MO, bool IsCallOp) {
|
||||
}
|
||||
|
||||
case MachineOperand::MO_ConstantPoolIndex:
|
||||
O << "$CPI" << CurrentFnName << "_" << MO.getConstantPoolIndex();
|
||||
O << PrivateGlobalPrefix << "CPI" << CurrentFnName << "_"
|
||||
<< MO.getConstantPoolIndex();
|
||||
return;
|
||||
|
||||
case MachineOperand::MO_ExternalSymbol:
|
||||
@ -222,8 +224,8 @@ void AlphaAsmPrinter::printConstantPool(MachineConstantPool *MCP) {
|
||||
for (unsigned i = 0, e = CP.size(); i != e; ++i) {
|
||||
// SwitchSection(O, "section .rodata, \"dr\"");
|
||||
emitAlignment(TD.getTypeAlignmentShift(CP[i]->getType()));
|
||||
O << "$CPI" << CurrentFnName << "_" << i << ":\t\t\t\t\t" << CommentString
|
||||
<< *CP[i] << "\n";
|
||||
O << PrivateGlobalPrefix << "CPI" << CurrentFnName << "_" << i
|
||||
<< ":\t\t\t\t\t" << CommentString << *CP[i] << "\n";
|
||||
emitGlobalConstant(CP[i]);
|
||||
}
|
||||
}
|
||||
|
@ -88,8 +88,8 @@ void IA64SharedAsmPrinter::printConstantPool(MachineConstantPool *MCP) {
|
||||
// FIXME: would be nice to have rodata (no 'w') when appropriate?
|
||||
for (unsigned i = 0, e = CP.size(); i != e; ++i) {
|
||||
emitAlignment(TD.getTypeAlignmentShift(CP[i]->getType()));
|
||||
O << ".CPI" << CurrentFnName << "_" << i << ":\t\t\t\t\t" << CommentString
|
||||
<< *CP[i] << "\n";
|
||||
O << PrivateGlobalPrefix << "CPI" << CurrentFnName << "_" << i
|
||||
<< ":\t\t\t\t\t" << CommentString << *CP[i] << "\n";
|
||||
emitGlobalConstant(CP[i]);
|
||||
}
|
||||
}
|
||||
@ -357,7 +357,7 @@ void IA64AsmPrinter::printOp(const MachineOperand &MO,
|
||||
return;
|
||||
|
||||
case MachineOperand::MO_ConstantPoolIndex: {
|
||||
O << "@gprel(.CPI" << CurrentFnName << "_"
|
||||
O << "@gprel(" << PrivateGlobalPrefix << "CPI" << CurrentFnName << "_"
|
||||
<< MO.getConstantPoolIndex() << ")";
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user