diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-04-12 18:11:31 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-04-12 18:11:31 +0000 |
commit | 0840f50b7652558f33fea38948592cf15857574a (patch) | |
tree | bfbaf82a8193c42a6fbbc9f5fe6bf10bd8cdcb83 /llvm/lib/CodeGen/SplitKit.h | |
parent | 68e84581c5155b238b455bea62314d92650e3787 (diff) | |
download | bcm5719-llvm-0840f50b7652558f33fea38948592cf15857574a.tar.gz bcm5719-llvm-0840f50b7652558f33fea38948592cf15857574a.zip |
Add SplitKit API to query and select the current interval being worked on.
This makes it possible to target multiple registers in one pass.
llvm-svn: 129374
Diffstat (limited to 'llvm/lib/CodeGen/SplitKit.h')
-rw-r--r-- | llvm/lib/CodeGen/SplitKit.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SplitKit.h b/llvm/lib/CodeGen/SplitKit.h index f1ff501fbdd..fab56f70d9b 100644 --- a/llvm/lib/CodeGen/SplitKit.h +++ b/llvm/lib/CodeGen/SplitKit.h @@ -283,7 +283,15 @@ public: void reset(LiveRangeEdit&); /// Create a new virtual register and live interval. - void openIntv(); + /// Return the interval index, starting from 1. Interval index 0 is the + /// implicit complement interval. + unsigned openIntv(); + + /// currentIntv - Return the current interval index. + unsigned currentIntv() const { return OpenIdx; } + + /// selectIntv - Select a previously opened interval index. + void selectIntv(unsigned Idx); /// enterIntvBefore - Enter the open interval before the instruction at Idx. /// If the parent interval is not live before Idx, a COPY is not inserted. |