1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00

add relocation support for ppc64 branches.

llvm-svn: 32284
This commit is contained in:
Chris Lattner 2006-12-06 19:40:04 +00:00
parent dea0f73f39
commit d4e8f5d141

View File

@ -127,11 +127,11 @@ int PPCCodeEmitter::getMachineOpValue(MachineInstr &MI, MachineOperand &MO) {
} else if (MO.isGlobalAddress() || MO.isExternalSymbol() ||
MO.isConstantPoolIndex() || MO.isJumpTableIndex()) {
unsigned Reloc = 0;
if (MI.getOpcode() == PPC::BL)
if (MI.getOpcode() == PPC::BL || MI.getOpcode() == PPC::BL8)
Reloc = PPC::reloc_pcrel_bx;
else {
switch (MI.getOpcode()) {
default: DEBUG(MI.dump()); assert(0 && "Unknown instruction for relocation!");
default: MI.dump(); assert(0 && "Unknown instruction for relocation!");
case PPC::LIS:
case PPC::LIS8:
case PPC::ADDIS: