diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2012-06-22 16:46:44 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2012-06-22 16:46:44 +0000 |
commit | 241d0209a765c97c684b120527e185f17723f650 (patch) | |
tree | e752711f5b5e3f95f4f58a8bc6a0462da407597c /lib/CodeGen/RegisterCoalescer.cpp | |
parent | 7ee3ca10f53aacce1f3aa052f81f9598ac09db33 (diff) | |
download | llvm-241d0209a765c97c684b120527e185f17723f650.tar.gz llvm-241d0209a765c97c684b120527e185f17723f650.tar.bz2 llvm-241d0209a765c97c684b120527e185f17723f650.tar.xz |
Remove LiveIntervals::trackingRegUnits().
With regunit liveness permanently enabled, this function would always
return true.
Also remove now obsolete code for checking physreg interference.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159006 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/RegisterCoalescer.cpp')
-rw-r--r-- | lib/CodeGen/RegisterCoalescer.cpp | 24 |
1 files changed, 5 insertions, 19 deletions
diff --git a/lib/CodeGen/RegisterCoalescer.cpp b/lib/CodeGen/RegisterCoalescer.cpp index de58b82d3a..4f30277317 100644 --- a/lib/CodeGen/RegisterCoalescer.cpp +++ b/lib/CodeGen/RegisterCoalescer.cpp @@ -1100,26 +1100,12 @@ bool RegisterCoalescer::joinReservedPhysReg(CoalescerPair &CP) { // Deny any overlapping intervals. This depends on all the reserved // register live ranges to look like dead defs. - if (LIS->trackingRegUnits()) { - for (MCRegUnitIterator UI(CP.getDstReg(), TRI); UI.isValid(); ++UI) - if (RHS.overlaps(LIS->getRegUnit(*UI))) { - DEBUG(dbgs() << "\t\tInterference: " << PrintRegUnit(*UI, TRI) << '\n'); - return false; - } - } else { - for (MCRegAliasIterator AS(CP.getDstReg(), TRI, true); AS.isValid(); ++AS) { - if (!LIS->hasInterval(*AS)) { - // Make sure at least DstReg itself exists before attempting a join. - if (*AS == CP.getDstReg()) - LIS->getOrCreateInterval(CP.getDstReg()); - continue; - } - if (RHS.overlaps(LIS->getInterval(*AS))) { - DEBUG(dbgs() << "\t\tInterference: " << PrintReg(*AS, TRI) << '\n'); - return false; - } + for (MCRegUnitIterator UI(CP.getDstReg(), TRI); UI.isValid(); ++UI) + if (RHS.overlaps(LIS->getRegUnit(*UI))) { + DEBUG(dbgs() << "\t\tInterference: " << PrintRegUnit(*UI, TRI) << '\n'); + return false; } - } + // Skip any value computations, we are not adding new values to the // reserved register. Also skip merging the live ranges, the reserved // register live range doesn't need to be accurate as long as all the |