From 00a8c0199901db28ecd2e96f9e1abb017991060c Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 24 Nov 2004 02:03:44 +0000 Subject: [PATCH] Loads are relocatable too git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18198 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/PowerPC/PPCCodeEmitter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Target/PowerPC/PPCCodeEmitter.cpp b/lib/Target/PowerPC/PPCCodeEmitter.cpp index 68f9cccc4ad..2b0c0cfa73f 100644 --- a/lib/Target/PowerPC/PPCCodeEmitter.cpp +++ b/lib/Target/PowerPC/PPCCodeEmitter.cpp @@ -197,7 +197,8 @@ int PPC32CodeEmitter::getMachineOpValue(MachineInstr &MI, MachineOperand &MO) { assert(MovePCtoLROffset && "MovePCtoLR not seen yet?"); Reloc = PPC::reloc_absolute_loadhi; Offset = -((intptr_t)MovePCtoLROffset+4); - } else if (MI.getOpcode() == PPC::LA) { + } else if (MI.getOpcode() == PPC::LA || MI.getOpcode() == PPC::LWZ || + MI.getOpcode() == PPC::LFS || MI.getOpcode() == PPC::LFD) { assert(MovePCtoLROffset && "MovePCtoLR not seen yet?"); Reloc = PPC::reloc_absolute_la; Offset = -((intptr_t)MovePCtoLROffset+4);