diff options
author | Evan Cheng <evan.cheng@apple.com> | 2011-11-14 21:02:09 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2011-11-14 21:02:09 +0000 |
commit | 41e00172c51a1666cbcda5df2c6f45d685068fbb (patch) | |
tree | 35fb445deec5b181c576263f439174095e39770f /lib/CodeGen/TwoAddressInstructionPass.cpp | |
parent | 4d0a9ff36574da0c042e9bd3ae816301b392ac41 (diff) |
At -O0, multiple uses of a virtual registers in the same BB are being marked
"kill". This looks like a bug upstream. Since that's going to take some time
to understand, loosen the assertion and disable the optimization when
multiple kills are seen.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144568 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/TwoAddressInstructionPass.cpp')
-rw-r--r-- | lib/CodeGen/TwoAddressInstructionPass.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/CodeGen/TwoAddressInstructionPass.cpp b/lib/CodeGen/TwoAddressInstructionPass.cpp index 33ed4cc907..a702c6c840 100644 --- a/lib/CodeGen/TwoAddressInstructionPass.cpp +++ b/lib/CodeGen/TwoAddressInstructionPass.cpp @@ -502,7 +502,8 @@ MachineInstr *findLocalKill(unsigned Reg, MachineBasicBlock *MBB, continue; if (!UI.getOperand().isKill()) return 0; - assert(!KillMI && "More than one local kills?"); + if (KillMI) + return 0; // -O0 kill markers cannot be trusted? KillMI = UseMI; } |