If a virtual register is copied and another copy was already
seen, replace with the previous copy.
This pattern shows up from various operand restrictions
AMDGPU has which require inserting copies depending
on the register class of the operands.
Paths
| Differential D13123
PeepholeOptimizer: Remove redundant copies ClosedPublic Authored by arsenm on Sep 23 2015, 7:00 PM.
Details
Diff Detail Event Timelinearsenm updated this object. This revision is now accepted and ready to land.Sep 24 2015, 2:51 AM qcolombet edited edge metadata. Comment ActionsHi Matt, I’m fine with the patch modulo few nitpicks. That being said, we can reconsider when we see motivating examples. Cheers,
Comment Actions r248611
Revision Contents
Diff 35582 lib/CodeGen/PeepholeOptimizer.cpp
test/CodeGen/AMDGPU/address-space.ll
test/CodeGen/AMDGPU/use-sgpr-multiple-times.ll
|
Please described the other arguments and how they are modified/use within the method.