llvm-project/llvm/test/Transforms/LoopVectorize/X86
Roman Tereshin 02320eee6b Revert "[SCEV][NFC] Check NoWrap flags before lexicographical comparison of SCEVs"
This reverts r319889.

Unfortunately, wrapping flags are not a part of SCEV's identity (they
do not participate in computing a hash value or in equality
comparisons) and in fact they could be assigned after the fact w/o
rebuilding a SCEV.

Grep for const_cast's to see quite a few of examples, apparently all
for AddRec's at the moment.

So, if 2 expressions get built in 2 slightly different ways: one with
flags set in the beginning, the other with the flags attached later
on, we may end up with 2 expressions which are exactly the same but
have their operands swapped in one of the commutative N-ary
expressions, and at least one of them will have "sorted by complexity"
invariant broken.

2 identical SCEV's won't compare equal by pointer comparison as they
are supposed to.

A real-world reproducer is added as a regression test: the issue
described causes 2 identical SCEV expressions to have different order
of operands and therefore compare not equal, which in its turn
prevents LoadStoreVectorizer from vectorizing a pair of consecutive
loads.

On a larger example (the source of the test attached, which is a
bugpoint) I have seen even weirder behavior: adding a constant to an
existing SCEV changes the order of the existing terms, for instance,
getAddExpr(1, ((A * B) + (C * D))) returns (1 + (C * D) + (A * B)).

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

llvm-svn: 340777
2018-08-27 21:41:37 +00:00
..
already-vectorized.ll
assume.ll
avx1.ll
avx512.ll [X86] Add support for passing 'prefer-vector-width' function attribute into X86Subtarget and exposing via X86's getRegisterWidth TTI interface. 2018-01-20 00:26:08 +00:00
consecutive-ptr-cg-bug.ll [SCEV] Smart range calculation for SCEVUnknown Phis 2018-03-01 06:56:48 +00:00
consecutive-ptr-uniforms.ll
constant-fold.ll [ConstantFold] Disallow folding vector geps into bitcasts 2018-06-01 19:34:35 +00:00
constant-vector-operand.ll
conversion-cost.ll
cost-model.ll
float-induction-x86.ll [SimplifyCFG] use pass options and remove the latesimplifycfg pass 2017-10-28 18:43:07 +00:00
force-ifcvt.ll
fp32_to_uint32-cost-model.ll
fp64_to_uint32-cost-model.ll
fp_to_sint8-cost-model.ll
funclet.ll
gather-cost.ll
gather-vs-interleave.ll
gather_scatter.ll [LV] Fix test checks, NFC. 2018-02-20 19:49:25 +00:00
gcc-examples.ll
illegal-parallel-loop-uniform-write.ll
imprecise-through-phis.ll revert r325515: [TTI CostModel] change default cost of FP ops to 1 (PR36280) 2018-02-21 01:42:52 +00:00
int128_no_gather.ll
interleaving.ll
lit.local.cfg
masked_load_store.ll Revert "[InstCombine] Delay foldICmpUsingKnownBits until simple transforms are done" 2018-07-06 04:04:13 +00:00
max-mstore.ll
metadata-enable.ll [LV] Preserve inbounds on created GEPs 2018-05-01 15:35:08 +00:00
min-trip-count-switch.ll
mul_slm_16bit.ll
no-vector.ll
no_fpmath.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
no_fpmath_with_hotness.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
parallel-loops-after-reg2mem.ll
parallel-loops.ll
powof2div.ll
pr23997.ll [X86][CET] Changing -fcf-protection behavior to comply with gcc (LLVM part) 2018-05-18 11:58:25 +00:00
pr34438.ll LoopVectorize: MaxVF should not be larger than the loop trip count 2017-09-04 08:35:13 +00:00
pr35432.ll Revert "[SCEV][NFC] Check NoWrap flags before lexicographical comparison of SCEVs" 2018-08-27 21:41:37 +00:00
pr36524.ll Revert r325687 (workaround for PR36032). 2018-03-22 22:04:39 +00:00
propagate-metadata.ll
ptr-indvar-crash.ll
rauw-bug.ll
reduction-crash.ll
reduction-small-size.ll [LV] Ignore the cost of values that will not appear in the vectorized loop 2017-12-12 08:57:43 +00:00
redundant-vf2-cost.ll Move redundant-vf2-cost.ll test to X86 directory 2018-06-15 18:46:03 +00:00
reg-usage-debug.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
reg-usage.ll [LV] Avoid computing the register usage for default VF. NFC 2017-09-13 19:35:45 +00:00
register-assumption.ll
scatter_crash.ll
slm-no-vectorize.ll
small-size.ll
strided_load_cost.ll
struct-store.ll
svml-calls-finite.ll
svml-calls.ll [TargetLibraryInfo] add mappings from LLVM sin/cos intrinsics to SVML calls 2018-06-07 18:21:24 +00:00
tripcount.ll
uint64_to_fp64-cost-model.ll
uniform-phi.ll
uniform_load.ll
uniformshift.ll
unroll-pm.ll
unroll-small-loops.ll
unroll_selection.ll
veclib-calls.ll
vect.omp.force.ll
vect.omp.force.small-tc.ll
vector-scalar-select-cost.ll
vector_max_bandwidth.ll NFC - Various typo fixes in tests 2018-07-04 13:28:39 +00:00
vector_ptr_load_store.ll
vectorization-remarks-loopid-dbg.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
vectorization-remarks-missed.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
vectorization-remarks-profitable.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
vectorization-remarks.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
vectorize-only-for-real.ll
x86-predication.ll [LV] Introduce VPBlendRecipe, VPWidenMemoryInstructionRecipe 2017-11-14 12:09:30 +00:00
x86_fp80-vector-store.ll