summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/ARM/ARMCodeEmitter.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2008-11-07 22:57:53 +0000
committerEvan Cheng <evan.cheng@apple.com>2008-11-07 22:57:53 +0000
commitef4d78ba67d4917716a15adfa127a507ffe7b62c (patch)
treed0119d203ea2b51498b9ae1c2b0230ba334a9b5f /llvm/lib/Target/ARM/ARMCodeEmitter.cpp
parent160be0ffdab141fd309344edfdc486db77154ef9 (diff)
downloadbcm5719-llvm-ef4d78ba67d4917716a15adfa127a507ffe7b62c.tar.gz
bcm5719-llvm-ef4d78ba67d4917716a15adfa127a507ffe7b62c.zip
More code clean up.
llvm-svn: 58872
Diffstat (limited to 'llvm/lib/Target/ARM/ARMCodeEmitter.cpp')
-rw-r--r--llvm/lib/Target/ARM/ARMCodeEmitter.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/lib/Target/ARM/ARMCodeEmitter.cpp b/llvm/lib/Target/ARM/ARMCodeEmitter.cpp
index 8c7e2aba89b..32cf226c497 100644
--- a/llvm/lib/Target/ARM/ARMCodeEmitter.cpp
+++ b/llvm/lib/Target/ARM/ARMCodeEmitter.cpp
@@ -140,7 +140,7 @@ namespace {
/// Routines that handle operands which add machine relocations which are
/// fixed up by the relocation stage.
void emitGlobalAddress(GlobalValue *GV, unsigned Reloc,
- bool NeedStub, unsigned CPIdx = 0);
+ bool NeedStub, intptr_t ACPV = 0);
void emitExternalSymbolAddress(const char *ES, unsigned Reloc);
void emitConstPoolAddress(unsigned CPI, unsigned Reloc);
void emitJumpTableAddress(unsigned JTIndex, unsigned Reloc);
@@ -225,11 +225,10 @@ unsigned ARMCodeEmitter::getMachineOpValue(const MachineInstr &MI,
/// emitGlobalAddress - Emit the specified address to the code stream.
///
-void ARMCodeEmitter::emitGlobalAddress(GlobalValue *GV,
- unsigned Reloc, bool NeedStub,
- unsigned CPIdx) {
+void ARMCodeEmitter::emitGlobalAddress(GlobalValue *GV, unsigned Reloc,
+ bool NeedStub, intptr_t ACPV) {
MCE.addRelocation(MachineRelocation::getGV(MCE.getCurrentPCOffset(),
- Reloc, GV, CPIdx, NeedStub));
+ Reloc, GV, ACPV, NeedStub));
}
/// emitExternalSymbolAddress - Arrange for the address of an external symbol to
@@ -337,7 +336,8 @@ void ARMCodeEmitter::emitConstPoolInstruction(const MachineInstr &MI) {
GlobalValue *GV = ACPV->getGV();
if (GV) {
assert(!ACPV->isStub() && "Don't know how to deal this yet!");
- emitGlobalAddress(GV, ARM::reloc_arm_machine_cp_entry, false, CPIndex);
+ emitGlobalAddress(GV, ARM::reloc_arm_machine_cp_entry, false,
+ (intptr_t)ACPV);
} else {
assert(!ACPV->isNonLazyPointer() && "Don't know how to deal this yet!");
emitExternalSymbolAddress(ACPV->getSymbol(), ARM::reloc_arm_absolute);
OpenPOWER on IntegriCloud