[PATCH] D50064: [MachineCopyPropagation] Improve redundant copy elimination
Alexander Ivchenko via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 31 07:24:43 PDT 2018
aivchenk created this revision.
aivchenk added reviewers: gberry, efriedma.
We can go a little further and delete the first copy here as well:
%R1 = COPY %R0 << Redundant
... // No clobber of %R1 and no uses of %R1 defined by the first copy.
%R0 = COPY killed %R1 << Redundant
In other words, The first copy is only used for defining a reg
that is used only in the second copy.
Previously, we deleted only the second copy as redundant.
https://reviews.llvm.org/D50064
Files:
lib/CodeGen/MachineCopyPropagation.cpp
test/CodeGen/X86/machine-copy-prop.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50064.158255.patch
Type: text/x-patch
Size: 4101 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180731/ad7a7905/attachment.bin>
More information about the llvm-commits
mailing list