diff options
author | Michael Liao <michael.hliao@gmail.com> | 2019-05-27 18:26:29 +0000 |
---|---|---|
committer | Michael Liao <michael.hliao@gmail.com> | 2019-05-27 18:26:29 +0000 |
commit | 9c70c574b4fec75f4c8a530891e6e412e7ad77be (patch) | |
tree | 061032339bf69b8552f61964d75564ca7ee46f46 /llvm/lib/Support/DebugCounter.cpp | |
parent | f4040a0dd81b1bb4d1a4704492d1642c09190f56 (diff) | |
download | bcm5719-llvm-9c70c574b4fec75f4c8a530891e6e412e7ad77be.tar.gz bcm5719-llvm-9c70c574b4fec75f4c8a530891e6e412e7ad77be.zip |
[SelectionDAG] Enhance the simplification of `copyto` from `implicit-def`.
Summary:
- The current implementation simplifies the case where the source of
`copyto` is `implicit-def`ed. However, it only works when that
`implicit-def` is single-used since it detects that from
`implicit-def` and cannot determine which destination vreg should be
used if there are multiple uses.
- This patch changes that detection when `copyto` is being emitted. If
that `copyto`'s source is defined from `implicit-def`, it simplifies
it. Hence, it works even that `implicit-def` is multi-used.
- Except it simplifies the internal IR, it won't improve the quality of
code generation. However, it helps to detect 'implicit-def` in a
straight-forward manner in some passes, such as `si-i1-copies`. A test
case is added.
Reviewers: sunfish, nhaehnle
Subscribers: jvesely, hiraditya, asbirlea, llvm-commits, yaxunl
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D62342
llvm-svn: 361777
Diffstat (limited to 'llvm/lib/Support/DebugCounter.cpp')
0 files changed, 0 insertions, 0 deletions