diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-11-01 19:49:57 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-11-01 19:49:57 +0000 |
commit | a37d5cf3425eb93a25cc5da2bbf9b6a47c757b45 (patch) | |
tree | 1a90e2425e1df05cd0d59435873394a7c426eaee /lib/CodeGen/LiveRangeEdit.cpp | |
parent | e8f0823a68cfc0201fffb100c7e4a1a2940cf9a9 (diff) | |
download | llvm-a37d5cf3425eb93a25cc5da2bbf9b6a47c757b45.tar.gz llvm-a37d5cf3425eb93a25cc5da2bbf9b6a47c757b45.tar.bz2 llvm-a37d5cf3425eb93a25cc5da2bbf9b6a47c757b45.tar.xz |
Don't assign new registers created during a split to the same stack slot, but
give them individual stack slots once the are actually spilled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117945 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveRangeEdit.cpp')
-rw-r--r-- | lib/CodeGen/LiveRangeEdit.cpp | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/lib/CodeGen/LiveRangeEdit.cpp b/lib/CodeGen/LiveRangeEdit.cpp index 21e43bf68e..bbcc07ca09 100644 --- a/lib/CodeGen/LiveRangeEdit.cpp +++ b/lib/CodeGen/LiveRangeEdit.cpp @@ -19,21 +19,12 @@ using namespace llvm; -int LiveRangeEdit::assignStackSlot(VirtRegMap &vrm) { - int ss = vrm.getStackSlot(getReg()); - if (ss != VirtRegMap::NO_STACK_SLOT) - return ss; - return vrm.assignVirt2StackSlot(getReg()); -} - LiveInterval &LiveRangeEdit::create(MachineRegisterInfo &mri, LiveIntervals &lis, VirtRegMap &vrm) { const TargetRegisterClass *RC = mri.getRegClass(parent_.reg); unsigned VReg = mri.createVirtualRegister(RC); vrm.grow(); - // Immediately assign to the same stack slot as parent. - vrm.assignVirt2StackSlot(VReg, assignStackSlot(vrm)); LiveInterval &li = lis.getOrCreateInterval(VReg); newRegs_.push_back(&li); return li; |