Skip to content

Commit

Permalink
My earlier "fix" for PBQP (see r165201) was incorrect. The real issue…
Browse files Browse the repository at this point in the history
… was that

checkRegMaskInterference only initializes the bitmask on the first interference.

This fixes PR14027 and (re)fixes PR13945.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165608 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
lhames committed Oct 10, 2012
1 parent 11d0042 commit 8a8cf96
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/CodeGen/RegAllocPBQP.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ std::auto_ptr<PBQPRAProblem> PBQPBuilder::build(MachineFunction *mf,
LiveInterval *vregLI = &LIS->getInterval(vreg);

// Record any overlaps with regmask operands.
BitVector regMaskOverlaps(tri->getNumRegs());
BitVector regMaskOverlaps;
LIS->checkRegMaskInterference(*vregLI, regMaskOverlaps);

// Compute an initial allowed set for the current vreg.
Expand All @@ -231,7 +231,7 @@ std::auto_ptr<PBQPRAProblem> PBQPBuilder::build(MachineFunction *mf,
continue;

// vregLI crosses a regmask operand that clobbers preg.
if (!regMaskOverlaps.empty() && regMaskOverlaps.test(preg))
if (!regMaskOverlaps.empty() && !regMaskOverlaps.test(preg))
continue;

// vregLI overlaps fixed regunit interference.
Expand Down

0 comments on commit 8a8cf96

Please sign in to comment.