diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-01-18 21:13:27 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-01-18 21:13:27 +0000 |
commit | b5fa9333431673aac2ced8dea80152349a85cf6f (patch) | |
tree | e7d6a2a04137bec83640ed9f89766b702048d573 /lib/CodeGen/SplitKit.h | |
parent | fdcee77887372dbf6589d47cc33094965b679f24 (diff) |
Add RAGreedy methods for splitting live ranges around regions.
Analyze the live range's behavior entering and leaving basic blocks. Compute an
interference pattern for each allocation candidate, and use SpillPlacement to
find an optimal region where that register can be live.
This code is still not enabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123774 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SplitKit.h')
-rw-r--r-- | lib/CodeGen/SplitKit.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/CodeGen/SplitKit.h b/lib/CodeGen/SplitKit.h index 236986e4af..3e14dcf43d 100644 --- a/lib/CodeGen/SplitKit.h +++ b/lib/CodeGen/SplitKit.h @@ -50,6 +50,9 @@ public: typedef SmallPtrSet<const MachineInstr*, 16> InstrPtrSet; InstrPtrSet usingInstrs_; + // Sorted slot indexes of using instructions. + SmallVector<SlotIndex, 8> UseSlots; + // The number of instructions using curli in each basic block. typedef DenseMap<const MachineBasicBlock*, unsigned> BlockCountMap; BlockCountMap usingBlocks_; @@ -81,6 +84,11 @@ public: /// new interval. void clear(); + /// hasUses - Return true if MBB has any uses of curli. + bool hasUses(const MachineBasicBlock *MBB) const { + return usingBlocks_.lookup(MBB); + } + typedef SmallPtrSet<const MachineBasicBlock*, 16> BlockPtrSet; typedef SmallPtrSet<const MachineLoop*, 16> LoopPtrSet; |