1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 20:12:56 +02:00
llvm-mirror/test/Transforms/LoopDistribute
Adam Nemet 40fc6ceb9d [LAA] Hold bounds via ValueHandles during SCEV expansion
SCEV expansion can invalidate previously expanded values.  For example
in SCEVExpander::ReuseOrCreateCast, if we already have the requested
cast value but it's not at the desired location, a new cast is inserted
and the old cast will be invalidated.

Therefore, when expanding the bounds for the pointers, a later entry can
invalidate the IR value for an earlier one.  The fix is to store a value
handle rather than the value itself.

The newly added test has a more detailed description of how the bug
triggers.

This bug can have a negative but potentially highly variable performance
impact in Loop Distribution.  Because one of the bound values was
invalidated and is an undef expression now, InstCombine is free to
transform the array overlap check:

   Start0 <= End1 && Start1 <= End0

into:

   Start0 <= End1

So depending on the runtime location of the arrays, we would detect a
conflict and fall back on the original loop of the versioned loop.

Also tested compile time with SPEC2006 LTO bc files.

llvm-svn: 245760
2015-08-21 23:19:57 +00:00
..
basic-with-memchecks.ll [LAA] Merge memchecks for accesses separated by a constant offset 2015-07-08 09:16:33 +00:00
basic.ll
bounds-expansion-bug.ll [LAA] Hold bounds via ValueHandles during SCEV expansion 2015-08-21 23:19:57 +00:00
crash-in-memcheck-generation.ll
no-if-convert.ll
outside-use.ll [LoopDist] Improve variable names and comments in LoopVersioning class, NFC 2015-06-22 22:59:40 +00:00
program-order.ll
unknown-bounds-for-memchecks.ll [LoopDist] Add test for missing coverage 2015-08-12 00:21:59 +00:00