summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SplitKit.h
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-21 18:38:15 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-21 18:38:15 +0000
commit6a663b8dc8ed475c5d441c87887478e709a781ff (patch)
treec5fdbc7770beeb4cb6a822216328e195e3443d6e /llvm/lib/CodeGen/SplitKit.h
parentd861e8b7bebcb7a36a158955a795b36128033c66 (diff)
downloadbcm5719-llvm-6a663b8dc8ed475c5d441c87887478e709a781ff.tar.gz
bcm5719-llvm-6a663b8dc8ed475c5d441c87887478e709a781ff.zip
Allow allocatable ranges from global live range splitting to be split again.
These intervals are allocatable immediately after splitting, but they may be evicted because of later splitting. This is rare, but when it happens they should be split again. The remainder intervals that cannot be allocated after splitting still move directly to spilling. SplitEditor::finish can optionally provide a mapping from new live intervals back to the original interval indexes returned by openIntv(). Each original interval index can map to multiple new intervals after connected components have been separated. Dead code elimination may also add existing intervals to the list. The reverse mapping allows the SplitEditor client to treat the new intervals differently depending on the split region they came from. llvm-svn: 129925
Diffstat (limited to 'llvm/lib/CodeGen/SplitKit.h')
-rw-r--r--llvm/lib/CodeGen/SplitKit.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SplitKit.h b/llvm/lib/CodeGen/SplitKit.h
index cc41e2e321e..a8f59d44f6a 100644
--- a/llvm/lib/CodeGen/SplitKit.h
+++ b/llvm/lib/CodeGen/SplitKit.h
@@ -368,7 +368,10 @@ public:
/// finish - after all the new live ranges have been created, compute the
/// remaining live range, and rewrite instructions to use the new registers.
- void finish();
+ /// @param LRMap When not null, this vector will map each live range in Edit
+ /// back to the indices returned by openIntv.
+ /// There may be extra indices created by dead code elimination.
+ void finish(SmallVectorImpl<unsigned> *LRMap = 0);
/// dump - print the current interval maping to dbgs().
void dump() const;
OpenPOWER on IntegriCloud