From: Matt Arsenault Date: Tue, 25 Nov 2014 07:53:06 +0000 (+0000) Subject: R600/SI: Fix allocating flat_scr_lo / flat_scr_hi X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=commitdiff_plain;h=87926dfe7efbb3f01ef6f71becce3837b758aac5 R600/SI: Fix allocating flat_scr_lo / flat_scr_hi Only the super register flat_scr was marked as reserved, so in some cases with high register usage it would still try to allocate the subregisters. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222737 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/R600/SIRegisterInfo.cpp b/lib/Target/R600/SIRegisterInfo.cpp index cffea129de9..5dc0f755f14 100644 --- a/lib/Target/R600/SIRegisterInfo.cpp +++ b/lib/Target/R600/SIRegisterInfo.cpp @@ -40,6 +40,8 @@ BitVector SIRegisterInfo::getReservedRegs(const MachineFunction &MF) const { Reserved.set(AMDGPU::INDIRECT_BASE_ADDR); Reserved.set(AMDGPU::FLAT_SCR); + Reserved.set(AMDGPU::FLAT_SCR_LO); + Reserved.set(AMDGPU::FLAT_SCR_HI); // Reserve some VGPRs to use as temp registers in case we have to spill VGPRs Reserved.set(AMDGPU::VGPR255);