Revert functional change. This broke a bunch of tests.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Thu, 11 Feb 2010 21:19:44 +0000 (21:19 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Thu, 11 Feb 2010 21:19:44 +0000 (21:19 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95921 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/SimpleRegisterCoalescing.cpp

index ac19f48e6512f7b544ff37d39ce97a9a59ad551f..df5c0ef3751f04a3557a5b60d1919402e8ef8fe6 100644 (file)
@@ -1148,7 +1148,7 @@ SimpleRegisterCoalescing::isWinToJoinCrossClass(unsigned LargeReg,
   LiveInterval &SmallInt = li_->getInterval(SmallReg);
   unsigned LargeSize = li_->getApproximateInstructionCount(LargeInt);
   unsigned SmallSize = li_->getApproximateInstructionCount(SmallInt);
-  if (LargeSize > Threshold) {
+  if (SmallSize > Threshold || LargeSize > Threshold) {
     unsigned SmallUses = std::distance(mri_->use_nodbg_begin(SmallReg),
                                        mri_->use_nodbg_end());
     unsigned LargeUses = std::distance(mri_->use_nodbg_begin(LargeReg),