diff options
author | Lang Hames <lhames@gmail.com> | 2014-03-17 01:22:54 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2014-03-17 01:22:54 +0000 |
commit | 7c8189c6d3f8cf8b35127547b37e3aec557030d3 (patch) | |
tree | a222744a4e5b51905c23df386ca831c193291415 /llvm/lib/CodeGen/MachineInstr.cpp | |
parent | 4633727686a661f54348a2943e39213de432cc8f (diff) | |
download | bcm5719-llvm-7c8189c6d3f8cf8b35127547b37e3aec557030d3.tar.gz bcm5719-llvm-7c8189c6d3f8cf8b35127547b37e3aec557030d3.zip |
[X86] New and improved VZeroUpperInserter optimization.
- Adds support for inserting vzerouppers before tail-calls.
This is enabled implicitly by having MachineInstr::copyImplicitOps preserve
regmask operands, which allows VZeroUpperInserter to see where tail-calls use
vector registers.
- Fixes a bug that caused the previous version of this optimization to miss some
vzeroupper insertion points in loops. (Loops-with-vector-code that followed
loops-without-vector-code were mistakenly overlooked by the previous version).
- New algorithm never revisits instructions.
Fixes <rdar://problem/16228798>
llvm-svn: 204021
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineInstr.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp index bbb5cd203b1..9b9b7f089c0 100644 --- a/llvm/lib/CodeGen/MachineInstr.cpp +++ b/llvm/lib/CodeGen/MachineInstr.cpp @@ -1434,7 +1434,7 @@ void MachineInstr::copyImplicitOps(MachineFunction &MF, for (unsigned i = MI->getDesc().getNumOperands(), e = MI->getNumOperands(); i != e; ++i) { const MachineOperand &MO = MI->getOperand(i); - if (MO.isReg() && MO.isImplicit()) + if ((MO.isReg() && MO.isImplicit()) || MO.isRegMask()) addOperand(MF, MO); } } |