aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineCopyPropagation.cpp
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2017-02-04 02:27:13 +0000
committerMatthias Braun <matze@braunis.de>2017-02-04 02:27:13 +0000
commit776a1d7ecb43df2ccc0312fbf0a8647e94954975 (patch)
tree8bac26e0dde2260f8b1069df79e78f7540663505 /llvm/lib/CodeGen/MachineCopyPropagation.cpp
parentc7d67eef5a73d1288bc9e9ce4afde666cf587949 (diff)
downloadllvm-776a1d7ecb43df2ccc0312fbf0a8647e94954975.zip
llvm-776a1d7ecb43df2ccc0312fbf0a8647e94954975.tar.gz
llvm-776a1d7ecb43df2ccc0312fbf0a8647e94954975.tar.bz2
MachineCopyPropagation: Do not consider undef operands as clobbers
This was originally introduced in r278321 to work around correctness problems in the ExecutionDepsFix pass; Probably also to keep the performance benefits of breaking the false dependencies which of course also affect undef operands. ExecutionDepsFix has been improved here recently (see for example r278321) so we should not need this exception any longer. Differential Revision: https://reviews.llvm.org/D29525 llvm-svn: 294087
Diffstat (limited to 'llvm/lib/CodeGen/MachineCopyPropagation.cpp')
-rw-r--r--llvm/lib/CodeGen/MachineCopyPropagation.cpp8
1 files changed, 0 insertions, 8 deletions
diff --git a/llvm/lib/CodeGen/MachineCopyPropagation.cpp b/llvm/lib/CodeGen/MachineCopyPropagation.cpp
index 92d043d..8662a30 100644
--- a/llvm/lib/CodeGen/MachineCopyPropagation.cpp
+++ b/llvm/lib/CodeGen/MachineCopyPropagation.cpp
@@ -280,14 +280,6 @@ void MachineCopyPropagation::CopyPropagateBlock(MachineBasicBlock &MBB) {
MaybeDeadCopies.remove(CI->second);
}
}
- // Treat undef use like defs for copy propagation but not for
- // dead copy. We would need to do a liveness check to be sure the copy
- // is dead for undef uses.
- // The backends are allowed to do whatever they want with undef value
- // and we cannot be sure this register will not be rewritten to break
- // some false dependencies for the hardware for instance.
- if (MO.isUndef())
- Defs.push_back(Reg);
}
// The instruction has a register mask operand which means that it clobbers