From cf1b5bd60ab7cf907bef20c3997ffb249b4fe90a Mon Sep 17 00:00:00 2001 From: Richard Sandiford Date: Fri, 5 Jul 2013 14:02:01 +0000 Subject: [SystemZ] Enable the use of MVC for frame-to-frame spills ...now that the problem that prompted the restriction has been fixed. The original spill-02.py was a compromise because at the time I couldn't find an example that actually failed without the two scavenging slots. The version included here did. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185701 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/SystemZ/SystemZInstrInfo.cpp | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'lib/Target') diff --git a/lib/Target/SystemZ/SystemZInstrInfo.cpp b/lib/Target/SystemZ/SystemZInstrInfo.cpp index 16207b3..12bcd09 100644 --- a/lib/Target/SystemZ/SystemZInstrInfo.cpp +++ b/lib/Target/SystemZ/SystemZInstrInfo.cpp @@ -363,18 +363,11 @@ SystemZInstrInfo::foldMemoryOperandImpl(MachineFunction &MF, // not valid in cases where the two memories partially overlap; however, // that is not a problem here, because we know that one of the memories // is a full frame index. - // - // For now we punt if the load or store is also to a frame index. - // In that case we might end up eliminating both of them to out-of-range - // offsets, which might then force the register scavenger to spill two - // other registers. The backend can only handle one such scavenger spill - // at a time. if (OpNum == 0 && MI->hasOneMemOperand()) { MachineMemOperand *MMO = *MI->memoperands_begin(); if (MMO->getSize() == Size && !MMO->isVolatile()) { // Handle conversion of loads. - if (isSimpleBD12Move(MI, SystemZII::SimpleBDXLoad) && - !MI->getOperand(1).isFI()) { + if (isSimpleBD12Move(MI, SystemZII::SimpleBDXLoad)) { uint64_t Offset = 0; MachineMemOperand *FrameMMO = getFrameMMO(MF, FrameIndex, Offset, MachineMemOperand::MOStore); @@ -384,8 +377,7 @@ SystemZInstrInfo::foldMemoryOperandImpl(MachineFunction &MF, .addMemOperand(FrameMMO).addMemOperand(MMO); } // Handle conversion of stores. - if (isSimpleBD12Move(MI, SystemZII::SimpleBDXStore) && - !MI->getOperand(1).isFI()) { + if (isSimpleBD12Move(MI, SystemZII::SimpleBDXStore)) { uint64_t Offset = 0; MachineMemOperand *FrameMMO = getFrameMMO(MF, FrameIndex, Offset, MachineMemOperand::MOLoad); -- cgit v1.1