hanchenye-llvm-project/llvm/test/Transforms/SROA
Bjorn Pettersson 81a76a388a [SROA] Handle PHI with multiple duplicate predecessors
Summary:
The verifier accepts PHI nodes with multiple entries for the
same basic block, as long as the value is the same.

As seen in PR37203, SROA did not handle such PHI nodes properly
when speculating loads over the PHI, since it inserted multiple
loads in the predecessor block and changed the PHI into having
multiple entries for the same basic block, but with different
values.

This patch teaches SROA to reuse the same speculated load for
each PHI duplicate entry in such situations.

Resolves: https://bugs.llvm.org/show_bug.cgi?id=37203

Reviewers: uabelho, chandlerc, hfinkel, bkramer, efriedma

Reviewed By: efriedma

Subscribers: dberlin, efriedma, llvm-commits

Differential Revision: https://reviews.llvm.org/D46426

llvm-svn: 332577
2018-05-17 07:21:41 +00:00
..
address-spaces.ll
alignment.ll
alloca-address-space.ll
basictest.ll [SROA] Take advantage of separate alignments for memcpy source and destination 2018-03-13 14:25:33 +00:00
big-endian.ll
dbg-addr-diamond.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
dbg-single-piece.ll
dead-inst.ll
fca.ll
mem-par-metadata-sroa.ll
non-integral-pointers.ll
phi-and-select.ll
phi-with-duplicate-pred.ll [SROA] Handle PHI with multiple duplicate predecessors 2018-05-17 07:21:41 +00:00
ppcf128-no-fold.ll
pr26972.ll
pr37267.ll [SROA] pr37267: fix assertion failure in integer widening 2018-05-17 06:32:17 +00:00
preserve-nonnull.ll
slice-order-independence.ll
slice-width.ll
vector-conversion.ll
vector-lifetime-intrinsic.ll
vector-promotion.ll
vectors-of-pointers.ll