diff options
| author | Mikael Holmen <mikael.holmen@ericsson.com> | 2018-03-28 06:01:30 +0000 |
|---|---|---|
| committer | Mikael Holmen <mikael.holmen@ericsson.com> | 2018-03-28 06:01:30 +0000 |
| commit | 6c062b7641623b1cfd2f359edb3118a4810c965e (patch) | |
| tree | c35c8e2ad075208885110cbd4a350bcf19db7a3b /llvm/lib/Target/AVR/Disassembler/AVRDisassembler.cpp | |
| parent | b402580616617a5c2d80f3d1c343b8f74bd7c3b5 (diff) | |
| download | bcm5719-llvm-6c062b7641623b1cfd2f359edb3118a4810c965e.tar.gz bcm5719-llvm-6c062b7641623b1cfd2f359edb3118a4810c965e.zip | |
[RegisterCoalescing] Don't move COPY if it would interfere with another value
Summary:
RegisterCoalescer::removePartialRedundancy tries to hoist B = A from
BB0/BB2 to BB1:
BB1:
...
BB0/BB2: ----
B = A; |
... |
A = B; |
|-------
|
It does so if a number of conditions are fulfilled. However, it failed
to check if B was used by any of the terminators in BB1. Since we must
insert B = A before the terminators (since it's not a terminator itself),
this means that we could erroneously insert a new definition of B before a
use of it.
Reviewers: wmi, qcolombet
Reviewed By: wmi
Subscribers: MatzeB, llvm-commits, sdardis
Differential Revision: https://reviews.llvm.org/D44918
llvm-svn: 328689
Diffstat (limited to 'llvm/lib/Target/AVR/Disassembler/AVRDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions

