diff options
author | Lang Hames <lhames@gmail.com> | 2012-10-10 06:39:48 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2012-10-10 06:39:48 +0000 |
commit | 8a8cf9617cdc735f0425e828bb7a6f401c0cf0f6 (patch) | |
tree | 14032c753a9f3f3aef8bf781fe24e913a6a1b597 /lib/CodeGen/RegAllocPBQP.cpp | |
parent | 11d00420e42ba88c3b48cab997965a7be79315e2 (diff) | |
download | llvm-8a8cf9617cdc735f0425e828bb7a6f401c0cf0f6.tar.gz llvm-8a8cf9617cdc735f0425e828bb7a6f401c0cf0f6.tar.bz2 llvm-8a8cf9617cdc735f0425e828bb7a6f401c0cf0f6.tar.xz |
My earlier "fix" for PBQP (see r165201) was incorrect. The real issue 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
Diffstat (limited to 'lib/CodeGen/RegAllocPBQP.cpp')
-rw-r--r-- | lib/CodeGen/RegAllocPBQP.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/RegAllocPBQP.cpp b/lib/CodeGen/RegAllocPBQP.cpp index f2473681a5..984aab2a7a 100644 --- a/lib/CodeGen/RegAllocPBQP.cpp +++ b/lib/CodeGen/RegAllocPBQP.cpp @@ -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. @@ -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. |