1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 03:33:20 +01:00
llvm-mirror/test/Analysis/ScalarEvolution
Sanjoy Das 60e1014097 Bugfix: SCEVExpander incorrectly marks increment operations as no-wrap
(The change was landed in r230280 and caused the regression PR22674.
This version contains a fix and a test-case for PR22674).
    
When emitting the increment operation, SCEVExpander marks the
operation as nuw or nsw based on the flags on the preincrement SCEV.
This is incorrect because, for instance, it is possible that {-6,+,1}
is <nuw> while {-6,+,1}+1 = {-5,+,1} is not.
    
This change teaches SCEV to mark the increment as nuw/nsw only if it
can explicitly prove that the increment operation won't overflow.
    
Apart from the attached test case, another (more realistic)
manifestation of the bug can be seen in
Transforms/IndVarSimplify/pr20680.ll.

Differential Revision: http://reviews.llvm.org/D7778

llvm-svn: 230533
2015-02-25 20:02:59 +00:00
..
2007-07-15-NegativeStride.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
2007-08-06-MisinterpretBranch.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2007-08-06-Unsigned.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2007-09-27-LargeStepping.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2007-11-14-SignedAddRec.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2007-11-18-OrInstruction.ll
2008-02-11-ReversedCondition.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-02-12-SMAXTripCount.ll
2008-02-15-UMax.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-05-25-NegativeStepToZero.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-06-12-BinomialInt64.ll
2008-07-12-UnneededSelect1.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-07-12-UnneededSelect2.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-07-19-InfiniteLoop.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-07-19-WrappingIV.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-07-29-SGTTripCount.ll
2008-07-29-SMinExpr.ll
2008-08-04-IVOverflow.ll
2008-08-04-LongAddRec.ll
2008-11-02-QuadraticCrash.ll
2008-11-15-CubicOOM.ll
2008-11-18-LessThanOrEqual.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-11-18-Stride1.ll Rewrite SCEV's backedge taken count computation. 2013-11-06 02:08:26 +00:00
2008-11-18-Stride2.ll Rewrite SCEV's backedge taken count computation. 2013-11-06 02:08:26 +00:00
2008-12-08-FiniteSGE.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-12-11-SMaxOverflow.ll
2008-12-14-StrideAndSigned.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2008-12-15-DontUseSDiv.ll Rewrite SCEV's backedge taken count computation. 2013-11-06 02:08:26 +00:00
2009-01-02-SignedNegativeStride.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2009-04-22-TruncCast.ll Actually call FileCheck in tests 2014-02-16 13:27:39 +00:00
2009-05-09-PointerEdgeCount.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
2009-07-04-GroupConstantsWidthMismatch.ll
2010-09-03-RequiredTransitive.ll Add a check to the test Analysis/ScalarEvolution/2010-09-03-RequiredTransitive.ll 2012-12-30 01:42:34 +00:00
2011-03-09-ExactNoMaxBECount.ll Tests: rewrite 'opt ... %s' to 'opt ... < %s' so that opt does not emit a ModuleID 2012-12-30 02:33:22 +00:00
2011-04-26-FoldAddRec.ll Add newlines at end of test files, no functionality change 2013-07-13 22:00:58 +00:00
2011-10-04-ConstEvolve.ll
2012-03-26-LoadConstant.ll Actually call FileCheck in tests 2014-02-16 13:27:39 +00:00
2012-05-18-LoopPredRecurse.ll Fix known typos 2014-01-24 17:20:08 +00:00
2012-05-29-MulAddRec.ll
and-xor.ll Teach SCEV to handle more cases of 'and X, CST', specifically where CST is any number of contiguous 1 bits in a row, with any number of leading and trailing 0 bits. 2014-01-27 10:04:03 +00:00
avoid-infinite-recursion-0.ll
avoid-infinite-recursion-1.ll
avoid-smax-0.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
avoid-smax-1.ll
div-overflow.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
do-loop.ll FileCheck-ize tests. 2013-08-22 00:51:19 +00:00
fold.ll Fix crasher introduced in r200203 and caught by a libc++ buildbot. Don't assume that getMulExpr returns a SCEVMulExpr, it may have simplified it to something else! 2014-01-27 10:47:44 +00:00
how-far-to-zero.ll If the step value is a constant zero, the loop isn't going to terminate. Fixes 2012-06-28 23:44:57 +00:00
incorrect-nsw.ll Bugfix: SCEV incorrectly marks certain add recurrences as nsw 2015-02-09 18:34:55 +00:00
infer-prestart-no-wrap.ll Fix bug 22641 2015-02-24 01:02:42 +00:00
load-with-range-metadata.ll IR: Make metadata typeless in assembly 2014-12-15 19:07:53 +00:00
load.ll
max-trip-count-address-space.ll Teach ScalarEvolution about pointer address spaces 2013-09-10 19:55:24 +00:00
max-trip-count.ll Adding testcase for PR18886. 2014-05-27 06:44:25 +00:00
min-max-exprs.ll Allow ScalarEvolution to catch more min/max cases 2015-02-09 12:34:23 +00:00
nsw-offset-assume.ll Make use @llvm.assume for loop guards in ScalarEvolution 2014-09-07 21:37:59 +00:00
nsw-offset.ll Teach SCEV to handle more cases of 'and X, CST', specifically where CST is any number of contiguous 1 bits in a row, with any number of leading and trailing 0 bits. 2014-01-27 10:04:03 +00:00
nsw.ll [SCEV] Improve Scalar Evolution's use of no {un,}signed wrap flags 2014-10-31 11:40:32 +00:00
nw-sub-is-not-nw-add.ll Make ScalarEvolution less aggressive with respect to no-wrap flags. 2015-01-22 00:48:47 +00:00
pointer-sign-bits.ll -disable-output is no longer needed with -analyze. 2010-01-26 19:25:59 +00:00
pr3909.ll
pr22179.ll Fix PR22179. 2015-01-10 23:41:24 +00:00
pr22641.ll Fix bug 22641 2015-02-24 01:02:42 +00:00
pr22674.ll Bugfix: SCEVExpander incorrectly marks increment operations as no-wrap 2015-02-25 20:02:59 +00:00
scev-aa.ll
scev-expander-incorrect-nowrap.ll Bugfix: SCEVExpander incorrectly marks increment operations as no-wrap 2015-02-25 20:02:59 +00:00
scev-invalid.ll Fix SCEV forgetMemoizedResults should search and destroy backedge exprs. 2013-03-26 03:14:53 +00:00
scev-prestart-nowrap.ll Fix bug 22641 2015-02-24 01:02:42 +00:00
sext-inreg.ll
sext-iv-0.ll
sext-iv-1.ll Use FileCheck in a few tests. 2014-11-06 15:05:51 +00:00
sext-iv-2.ll
sle.ll
smax.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
SolveQuadraticEquation.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count2.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count3.ll Rewrite SCEV's backedge taken count computation. 2013-11-06 02:08:26 +00:00
trip-count4.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count5.ll
trip-count6.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count7.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count8.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
trip-count9.ll Rewrite SCEV's backedge taken count computation. 2013-11-06 02:08:26 +00:00
trip-count10.ll Unit test for SCEV fix r182989, PR16130. 2013-05-31 16:42:41 +00:00
trip-count11.ll Fix creating bitcasts between address spaces in SCEV. 2013-10-21 18:41:10 +00:00
trip-count12.ll
trip-count-pow2.ll ScalarEvolution: HowFarToZero was wrongly using signed division 2014-11-16 07:30:35 +00:00
trip-count-switch.ll ScalarEvolution: Analyze trip count of loops with a switch guarding the exit. 2014-02-11 15:44:32 +00:00
trip-count.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00
undefined.ll
unreachable-code.ll
unsimplified-loop.ll
zext-signed-addrec.ll Bugfix: SCEVExpander incorrectly marks increment operations as no-wrap 2015-02-25 20:02:59 +00:00
zext-wrap.ll FileCheckize some of the testcases. 2013-08-05 23:43:18 +00:00