summaryrefslogtreecommitdiff
path: root/lib/Target/PowerPC/PPCJITInfo.cpp
diff options
context:
space:
mode:
authorNate Begeman <natebegeman@mac.com>2006-04-21 22:04:15 +0000
committerNate Begeman <natebegeman@mac.com>2006-04-21 22:04:15 +0000
commit6fcbd6961d9f14d75e2b314b06ca823d43a70353 (patch)
tree3685acfbbe1c531a2a44741f8b4746eb8921621f /lib/Target/PowerPC/PPCJITInfo.cpp
parent99d3c276cc395ef451b0d601f57f5c8f134d9c75 (diff)
downloadllvm-6fcbd6961d9f14d75e2b314b06ca823d43a70353.tar.gz
llvm-6fcbd6961d9f14d75e2b314b06ca823d43a70353.tar.bz2
llvm-6fcbd6961d9f14d75e2b314b06ca823d43a70353.tar.xz
Change the PPC JIT to use a Static relocation model
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27937 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCJITInfo.cpp')
-rw-r--r--lib/Target/PowerPC/PPCJITInfo.cpp13
1 files changed, 1 insertions, 12 deletions
diff --git a/lib/Target/PowerPC/PPCJITInfo.cpp b/lib/Target/PowerPC/PPCJITInfo.cpp
index 872dff2fb5..6257ebd6cb 100644
--- a/lib/Target/PowerPC/PPCJITInfo.cpp
+++ b/lib/Target/PowerPC/PPCJITInfo.cpp
@@ -201,19 +201,8 @@ void PPCJITInfo::relocate(void *Function, MachineRelocation *MR,
"Relocation out of range!");
*RelocPos |= (ResultPtr & ((1 << 24)-1)) << 2;
break;
-
case PPC::reloc_absolute_ptr_high: // Pointer relocations.
- case PPC::reloc_absolute_ptr_low: {
- // Pointer relocations are used for the PPC external stubs and lazy
- // resolver pointers that the Darwin ABI likes to use. Basically, the
- // address of the global is actually stored in memory, and the address of
- // the pointer is relocated into instructions instead of the pointer
- // itself. Because we have to keep the mapping anyway, we just return
- // pointers to the values in the map as our new location.
- static std::set<void*> Pointers;
- ResultPtr = (intptr_t)&*Pointers.insert((void*)ResultPtr).first;
- }
- // FALL THROUGH
+ case PPC::reloc_absolute_ptr_low:
case PPC::reloc_absolute_high: // high bits of ref -> low 16 of instr
case PPC::reloc_absolute_low: // low bits of ref -> low 16 of instr
ResultPtr += MR->getConstantVal();