Fix PR10046 by updating LiveVariables kill info when splitting live ranges.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Sun, 29 May 2011 20:10:28 +0000 (20:10 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Sun, 29 May 2011 20:10:28 +0000 (20:10 +0000)
commit57903357ee4f9fed47dcad6f3739414301136b0f
tree7aecb2c8990380407de3412b3473f8b526ae7cce
parent5f8fd54f0891aa47f467498454f6a3df8ae62704
Fix PR10046 by updating LiveVariables kill info when splitting live ranges.

This only affects targets like Mips where branch instructions may kill virtual
registers. Most other targets branch on flag values, so virtual registers are
not involved.

The problem is that MachineBasicBlock::updateTerminator deletes branches and
inserts new ones while LiveVariables keeps a list of pointers to instructions
that kill virtual registers. That list wasn't properly updated in
MBB::SplitCriticalEdge.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132298 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/MachineBasicBlock.cpp
test/CodeGen/Mips/2011-05-26-BranchKillsVreg.ll [new file with mode: 0644]