Fix for PR26690

I mistook BitVector::empty() to mean BitVector::count() == 0 and it does
not. Corrected the issue with the fix for PR26500.

llvm-svn: 261525
This commit is contained in:
Nemanja Ivanovic 2016-02-22 14:47:49 +00:00
parent 451f54cf62
commit d58b976bb7
1 changed files with 1 additions and 1 deletions

View File

@ -653,7 +653,7 @@ PPCFrameLowering::findScratchRegister(MachineBasicBlock *MBB,
// Now that we've done our best to provide both registers, double check
// whether we were unable to provide enough.
if (BV.empty() || (BV.count() < 2 && TwoUniqueRegsRequired))
if (BV.count() < TwoUniqueRegsRequired ? 2 : 1)
return false;
return true;