diff options
author | dim <dim@FreeBSD.org> | 2016-01-22 21:50:08 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2016-01-22 21:50:08 +0000 |
commit | 6e0d73d099af288ba2ca9f4ac232abadd8cf2ca9 (patch) | |
tree | e322839f15ba2f181f0b3a5f2fe3a7be147bce82 /contrib/llvm/lib/Target/ARM | |
parent | 7cf07624a0c8bc9de65a351f13206cea487afb48 (diff) | |
download | FreeBSD-src-6e0d73d099af288ba2ca9f4ac232abadd8cf2ca9.zip FreeBSD-src-6e0d73d099af288ba2ca9f4ac232abadd8cf2ca9.tar.gz |
Update llvm and clang to release_38 branch r258549.
Diffstat (limited to 'contrib/llvm/lib/Target/ARM')
-rw-r--r-- | contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp b/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp index 37c0795..978e99c 100644 --- a/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp +++ b/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp @@ -12423,6 +12423,7 @@ void ARMTargetLowering::insertCopiesSplitCSR( const TargetInstrInfo *TII = Subtarget->getInstrInfo(); MachineRegisterInfo *MRI = &Entry->getParent()->getRegInfo(); + MachineBasicBlock::iterator MBBI = Entry->begin(); for (const MCPhysReg *I = IStart; *I; ++I) { const TargetRegisterClass *RC = nullptr; if (ARM::GPRRegClass.contains(*I)) @@ -12442,13 +12443,13 @@ void ARMTargetLowering::insertCopiesSplitCSR( Attribute::NoUnwind) && "Function should be nounwind in insertCopiesSplitCSR!"); Entry->addLiveIn(*I); - BuildMI(*Entry, Entry->begin(), DebugLoc(), TII->get(TargetOpcode::COPY), - NewVR) + BuildMI(*Entry, MBBI, DebugLoc(), TII->get(TargetOpcode::COPY), NewVR) .addReg(*I); + // Insert the copy-back instructions right before the terminator. for (auto *Exit : Exits) - BuildMI(*Exit, Exit->begin(), DebugLoc(), TII->get(TargetOpcode::COPY), - *I) + BuildMI(*Exit, Exit->getFirstTerminator(), DebugLoc(), + TII->get(TargetOpcode::COPY), *I) .addReg(NewVR); } } |