From e95e534732277335d083065cfd3aa8eed307d775 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Thu, 4 May 2017 21:40:16 +0000 Subject: [PATCH] Pull in r302183 from upstream llvm trunk (by Krzysztof Parzyszek): [PPC] When restoring R30 (PIC base pointer), mark it as This happened on the PPC32/SVR4 path and was discovered when building FreeBSD on PPC32. It was a typo-class error in the frame lowering code. This fixes PR26519. Reported by: Mark Millard PR: 206990 MFC after: 3 days --- contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp b/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp index e786ef9aee0e..2c4b17a8878d 100644 --- a/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp +++ b/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp @@ -1467,8 +1467,7 @@ void PPCFrameLowering::emitEpilogue(MachineFunction &MF, } if (FI->usesPICBase()) - BuildMI(MBB, MBBI, dl, LoadInst) - .addReg(PPC::R30) + BuildMI(MBB, MBBI, dl, LoadInst, PPC::R30) .addImm(PBPOffset) .addReg(RBReg);