diff options
author | Richard Sandiford <rsandifo@linux.vnet.ibm.com> | 2013-07-05 13:11:52 +0000 |
---|---|---|
committer | Richard Sandiford <rsandifo@linux.vnet.ibm.com> | 2013-07-05 13:11:52 +0000 |
commit | 47734db936bd3b434d60f9daee5b34bc722ee3ba (patch) | |
tree | 762d666959806fd85e031f0b5b0d336985c83bbd /lib/Target | |
parent | 61de142984aa6cb1acfe4725183193d04e437420 (diff) | |
download | external_llvm-47734db936bd3b434d60f9daee5b34bc722ee3ba.zip external_llvm-47734db936bd3b434d60f9daee5b34bc722ee3ba.tar.gz external_llvm-47734db936bd3b434d60f9daee5b34bc722ee3ba.tar.bz2 |
[SystemZ] Allocate a second register scavenging slot
This is another prerequisite for frame-to-frame MVC copies.
I'll commit the patch that makes use of the slot separately.
The downside of trying to test many corner cases with each of the
available addressing modes is that a fair few tests need to account
for the new frame layout. I do still think it's useful to have all
these tests though, since it's something that wouldn't get much coverage
otherwise.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185698 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target')
-rw-r--r-- | lib/Target/SystemZ/SystemZFrameLowering.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/Target/SystemZ/SystemZFrameLowering.cpp b/lib/Target/SystemZ/SystemZFrameLowering.cpp index 3ae5978..a58da90 100644 --- a/lib/Target/SystemZ/SystemZFrameLowering.cpp +++ b/lib/Target/SystemZ/SystemZFrameLowering.cpp @@ -270,10 +270,14 @@ processFunctionBeforeFrameFinalized(MachineFunction &MF, MachineFrameInfo *MFFrame = MF.getFrameInfo(); uint64_t MaxReach = (MFFrame->estimateStackSize(MF) + SystemZMC::CallFrameSize * 2); - if (!isUInt<12>(MaxReach)) - // We may need a register scavenging slot if some parts of the frame + if (!isUInt<12>(MaxReach)) { + // We may need register scavenging slots if some parts of the frame // are outside the reach of an unsigned 12-bit displacement. + // Create 2 for the case where both addresses in an MVC are + // out of range. RS->addScavengingFrameIndex(MFFrame->CreateStackObject(8, 8, false)); + RS->addScavengingFrameIndex(MFFrame->CreateStackObject(8, 8, false)); + } } // Emit instructions before MBBI (in MBB) to add NumBytes to Reg. |