summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/LiveIntervalUnion.h
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-11 23:57:14 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-11 23:57:14 +0000
commit507992e909825c807f7972626efabf476adea8f7 (patch)
tree21c885ee95ff4668a6b2a9583458dd29c716979f /llvm/lib/CodeGen/LiveIntervalUnion.h
parentdc8bf9ec08641477675c9d85cf9fcaa9c31487d5 (diff)
downloadbcm5719-llvm-507992e909825c807f7972626efabf476adea8f7.tar.gz
bcm5719-llvm-507992e909825c807f7972626efabf476adea8f7.zip
Reuse live interval union between functions. This saves a bit of compile time
when compiling many small functions. llvm-svn: 129321
Diffstat (limited to 'llvm/lib/CodeGen/LiveIntervalUnion.h')
-rw-r--r--llvm/lib/CodeGen/LiveIntervalUnion.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/LiveIntervalUnion.h b/llvm/lib/CodeGen/LiveIntervalUnion.h
index 90d4aaf88ad..c83578e99c6 100644
--- a/llvm/lib/CodeGen/LiveIntervalUnion.h
+++ b/llvm/lib/CodeGen/LiveIntervalUnion.h
@@ -95,6 +95,9 @@ public:
// Remove a live virtual register's segments from this union.
void extract(LiveInterval &VirtReg);
+ // Remove all inserted virtual registers.
+ void clear() { Segments.clear(); ++Tag; }
+
// Print union, using TRI to translate register names
void print(raw_ostream &OS, const TargetRegisterInfo *TRI) const;
OpenPOWER on IntegriCloud