summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AllocationOrder.h
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2015-07-15 22:16:00 +0000
committerMatthias Braun <matze@braunis.de>2015-07-15 22:16:00 +0000
commit5d1f12d1f5e42cd538a245216529b7cae59d01a0 (patch)
tree93326a222da006a9568a8b97612451ab1c45ecca /llvm/lib/CodeGen/AllocationOrder.h
parent37643a04a499a61ad800bcb526fe36e74b0b3636 (diff)
downloadbcm5719-llvm-5d1f12d1f5e42cd538a245216529b7cae59d01a0.tar.gz
bcm5719-llvm-5d1f12d1f5e42cd538a245216529b7cae59d01a0.zip
TargetRegisterInfo: Provide a way to check assigned registers in getRegAllocationHints()
Pass a const reference to LiveRegMatrix to getRegAllocationHints() because some targets can prodive better hints if they can test whether a physreg has been used for register allocation yet. llvm-svn: 242340
Diffstat (limited to 'llvm/lib/CodeGen/AllocationOrder.h')
-rw-r--r--llvm/lib/CodeGen/AllocationOrder.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/AllocationOrder.h b/llvm/lib/CodeGen/AllocationOrder.h
index 02b2d9250bc..2aee3a63a2b 100644
--- a/llvm/lib/CodeGen/AllocationOrder.h
+++ b/llvm/lib/CodeGen/AllocationOrder.h
@@ -24,6 +24,7 @@ namespace llvm {
class RegisterClassInfo;
class VirtRegMap;
+class LiveRegMatrix;
class LLVM_LIBRARY_VISIBILITY AllocationOrder {
SmallVector<MCPhysReg, 16> Hints;
@@ -37,7 +38,8 @@ public:
/// @param RegClassInfo Information about reserved and allocatable registers.
AllocationOrder(unsigned VirtReg,
const VirtRegMap &VRM,
- const RegisterClassInfo &RegClassInfo);
+ const RegisterClassInfo &RegClassInfo,
+ const LiveRegMatrix *Matrix);
/// Get the allocation order without reordered hints.
ArrayRef<MCPhysReg> getOrder() const { return Order; }
OpenPOWER on IntegriCloud