diff options
author | Brian Gaeke <gaeke@uiuc.edu> | 2004-05-04 21:09:02 +0000 |
---|---|---|
committer | Brian Gaeke <gaeke@uiuc.edu> | 2004-05-04 21:09:02 +0000 |
commit | f2ff5dd442fde39748daeae663001dd19d9c4c3f (patch) | |
tree | 472ad046560d11dee19cd979f4e4745704047fcd /llvm/lib | |
parent | b3a9a0fcbd55b57f631739ab9f8014da100603ab (diff) | |
download | bcm5719-llvm-f2ff5dd442fde39748daeae663001dd19d9c4c3f.tar.gz bcm5719-llvm-f2ff5dd442fde39748daeae663001dd19d9c4c3f.zip |
Correctly mangle function names when they are used as part of a
constant pool member's name.
This is intended to address Bug 333.
Also, fix an anachronistic usage of "M" as a parameter of type Function *.
llvm-svn: 13357
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Target/SparcV9/SparcV9AsmPrinter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Target/SparcV9/SparcV9AsmPrinter.cpp b/llvm/lib/Target/SparcV9/SparcV9AsmPrinter.cpp index 0f8c2cdc374..cf24c3a1234 100644 --- a/llvm/lib/Target/SparcV9/SparcV9AsmPrinter.cpp +++ b/llvm/lib/Target/SparcV9/SparcV9AsmPrinter.cpp @@ -651,7 +651,7 @@ SparcV9AsmPrinter::printOneOperand(const MachineOperand &mop, case MachineOperand::MO_ConstantPoolIndex: { - toAsm << ".CPI_" << currFunction->getName() + toAsm << ".CPI_" << getID(currFunction) << "_" << mop.getConstantPoolIndex(); break; } @@ -663,8 +663,8 @@ SparcV9AsmPrinter::printOneOperand(const MachineOperand &mop, if (const BasicBlock *BB = dyn_cast<BasicBlock>(Val)) toAsm << getID(BB); - else if (const Function *M = dyn_cast<Function>(Val)) - toAsm << getID(M); + else if (const Function *F = dyn_cast<Function>(Val)) + toAsm << getID(F); else if (const GlobalVariable *GV = dyn_cast<GlobalVariable>(Val)) toAsm << getID(GV); else if (const Constant *CV = dyn_cast<Constant>(Val)) |