aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/AllocationOrder.cpp
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2012-11-29 03:34:17 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2012-11-29 03:34:17 +0000
commit39b5c0c049a19c7a7feffc9506da07923cc136e4 (patch)
tree40e2fe5414f9c051805e7fcd282a671e844e8fbd /lib/CodeGen/AllocationOrder.cpp
parente26e8a64ab37e98c69801ac2028b187773bc1d1f (diff)
Use MCPhysReg for RegisterClassInfo allocation orders.
This saves a bit of memory. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168852 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AllocationOrder.cpp')
-rw-r--r--lib/CodeGen/AllocationOrder.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/AllocationOrder.cpp b/lib/CodeGen/AllocationOrder.cpp
index 96c907aa9c..bad4912e72 100644
--- a/lib/CodeGen/AllocationOrder.cpp
+++ b/lib/CodeGen/AllocationOrder.cpp
@@ -42,7 +42,7 @@ AllocationOrder::AllocationOrder(unsigned VirtReg,
if (HintPair.first) {
const TargetRegisterInfo &TRI = VRM.getTargetRegInfo();
// The remaining allocation order may depend on the hint.
- ArrayRef<uint16_t> Order =
+ ArrayRef<MCPhysReg> Order =
TRI.getRawAllocationOrder(RC, HintPair.first, Hint,
VRM.getMachineFunction());
if (Order.empty())
@@ -50,7 +50,7 @@ AllocationOrder::AllocationOrder(unsigned VirtReg,
// Copy the allocation order with reserved registers removed.
OwnedBegin = true;
- unsigned *P = new unsigned[Order.size()];
+ MCPhysReg *P = new MCPhysReg[Order.size()];
Begin = P;
for (unsigned i = 0; i != Order.size(); ++i)
if (!MRI.isReserved(Order[i]))
@@ -63,7 +63,7 @@ AllocationOrder::AllocationOrder(unsigned VirtReg,
} else {
// If there is no hint or just a normal hint, use the cached allocation
// order from RegisterClassInfo.
- ArrayRef<unsigned> O = RCI.getOrder(RC);
+ ArrayRef<MCPhysReg> O = RCI.getOrder(RC);
Begin = O.begin();
End = O.end();
}