diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-04-06 19:13:57 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-04-06 19:13:57 +0000 |
commit | 9efa2a263ea470caacef1c85f6ca45e32bf516d3 (patch) | |
tree | a53dc8a880e331f92a28e9d4d63711136a746fba /lib/CodeGen/RegAllocGreedy.cpp | |
parent | 77b42e9654c6c226d29aeb0883955874ea881068 (diff) |
Break the spill placement algorithm into three parts: prepare, addConstraints, and finish.
This will allow us to abort the algorithm early if it is determined to be futile.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129020 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/RegAllocGreedy.cpp')
-rw-r--r-- | lib/CodeGen/RegAllocGreedy.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/CodeGen/RegAllocGreedy.cpp b/lib/CodeGen/RegAllocGreedy.cpp index 4339a81b8f..4e8891f66f 100644 --- a/lib/CodeGen/RegAllocGreedy.cpp +++ b/lib/CodeGen/RegAllocGreedy.cpp @@ -770,7 +770,10 @@ unsigned RAGreedy::tryRegionSplit(LiveInterval &VirtReg, AllocationOrder &Order, continue; } - SpillPlacer->placeSpills(SplitConstraints, LiveBundles); + SpillPlacer->prepare(LiveBundles); + SpillPlacer->addConstraints(SplitConstraints); + SpillPlacer->finish(); + // No live bundles, defer to splitSingleBlocks(). if (!LiveBundles.any()) { DEBUG(dbgs() << " no bundles.\n"); |