diff options
| author | Chad Rosier <mcrosier@apple.com> | 2012-11-06 22:52:42 +0000 |
|---|---|---|
| committer | Chad Rosier <mcrosier@apple.com> | 2012-11-06 22:52:42 +0000 |
| commit | 8d2c22900659fbd7c0bfb71262161d2a4f10a480 (patch) | |
| tree | 58aa89b2a84466533e84357bcab52359d0e7f8d5 /llvm | |
| parent | b46a05cdf9761e863a054b26d6f29ced2099911c (diff) | |
| download | bcm5719-llvm-8d2c22900659fbd7c0bfb71262161d2a4f10a480.tar.gz bcm5719-llvm-8d2c22900659fbd7c0bfb71262161d2a4f10a480.zip | |
[regallocfast] Make sure the MachineRegisterInfo is aware of clobbers from a
register masks. This is an obvious and necessary fix for a soon to be committed
patch. No test case possible at this time. Reviewed by Jakob.
llvm-svn: 167498
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/lib/CodeGen/RegAllocFast.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/RegAllocFast.cpp b/llvm/lib/CodeGen/RegAllocFast.cpp index e426fe23c00..88922169b30 100644 --- a/llvm/lib/CodeGen/RegAllocFast.cpp +++ b/llvm/lib/CodeGen/RegAllocFast.cpp @@ -956,6 +956,11 @@ void RAFast::AllocateBasicBlock() { bool hasPhysDefs = false; for (unsigned i = 0, e = MI->getNumOperands(); i != e; ++i) { MachineOperand &MO = MI->getOperand(i); + // Make sure MRI knows about registers clobbered by regmasks. + if (MO.isRegMask()) { + MRI->addPhysRegsUsedFromRegMask(MO.getRegMask()); + continue; + } if (!MO.isReg()) continue; unsigned Reg = MO.getReg(); if (!Reg) continue; |

