llvm-project/llvm/test/Transforms/GVN/PRE
Serguei Katkov 722339e405 [GVN PRE] Patch the source for Phi node in PRE
We must patch all existing incoming values of Phi node,
otherwise it is possible that we can see poison
where program does not expect to see it.

This is the similar what GVN does.

The added test test/Transforms/GVN/PRE/pre-jt-add.ll shows an
example of wrong optimization done by jump threading due to
GVN PRE did not patch existing incoming value.

Reviewers: mkazantsev, wmi, dberlin, davide
Reviewed By: dberlin
Subscribers: efriedma, llvm-commits
Differential Revision: https://reviews.llvm.org/D39637

llvm-svn: 317768
2017-11-09 06:02:18 +00:00
..
2009-02-17-LoadPRECrash.ll
2009-06-17-InvalidPRE.ll
2011-06-01-NonLocalMemdepMiscompile.ll ConstantFold: Fold getelementptr (i32, i32* null, i64 undef) to null. 2017-05-08 17:37:29 +00:00
2017-06-28-pre-load-dbgloc.ll Fix DebugLoc propagation for unreachable LoadInst 2017-07-19 01:27:24 +00:00
2017-10-16-LoadPRECrash.ll Reapply "[GVN] Prevent LoadPRE from hoisting across instructions that don't pass control flow to successors" 2017-10-31 05:07:56 +00:00
atomic.ll Enhance synchscope representation 2017-07-11 22:23:00 +00:00
invariant-load.ll
load-metadata.ll
load-pre-align.ll
load-pre-licm.ll
load-pre-nonlocal.ll
local-pre.ll
lpre-call-wrap-2.ll
lpre-call-wrap.ll
nonintegral.ll [GVN] Fix a crash on encountering non-integral pointers 2017-05-09 21:07:20 +00:00
phi-translate-2.ll [GVN] Remove stale entries in phitranslate cache when new phi is generated for PRE 2017-08-08 21:40:14 +00:00
phi-translate.ll Fix DebugLoc propagation for unreachable LoadInst 2017-07-19 01:27:24 +00:00
pre-basic-add.ll
pre-gep-load.ll [GVN] Recommit the patch "Add phi-translate support in scalarpre" 2017-07-28 15:47:25 +00:00
pre-jt-add.ll [GVN PRE] Patch the source for Phi node in PRE 2017-11-09 06:02:18 +00:00
pre-load-guards.ll Reapply "[GVN] Prevent LoadPRE from hoisting across instructions that don't pass control flow to successors" 2017-10-31 05:07:56 +00:00
pre-load-implicit-cf-updates.ll Reapply "[GVN] Prevent LoadPRE from hoisting across instructions that don't pass control flow to successors" 2017-10-31 05:07:56 +00:00
pre-load.ll Reapply "[GVN] Prevent LoadPRE from hoisting across instructions that don't pass control flow to successors" 2017-10-31 05:07:56 +00:00
pre-no-cost-phi.ll
pre-poison-add.ll [GVN PRE] Patch the source for Phi node in PRE 2017-11-09 06:02:18 +00:00
pre-single-pred.ll
preserve-tbaa.ll
rle-addrspace-cast.ll opt: Rename -default-data-layout flag to -data-layout and make it always override the layout. 2017-02-17 17:36:52 +00:00
rle-phi-translate.ll
rle-semidominated.ll
rle.ll opt: Rename -default-data-layout flag to -data-layout and make it always override the layout. 2017-02-17 17:36:52 +00:00
volatile.ll