Add a basic verifier for SCEV's backedge taken counts.
authorBenjamin Kramer <benny.kra@googlemail.com>
Fri, 26 Oct 2012 17:31:32 +0000 (17:31 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Fri, 26 Oct 2012 17:31:32 +0000 (17:31 +0000)
commit214935ee70c26fca2a0d6c4916aaebe0de9d3e7f
treef7ac8e17a82c72c54ef6bb919ad87aec319a741f
parent15198e94d2faab4f7b0afd8c82a84f2688820ae9
Add a basic verifier for SCEV's backedge taken counts.

Enabled with -verify-scev. This could be extended significantly but hopefully
catches the common cases now. Note that it's not enabled by default in any
configuration because the way it tries to distinguish SCEVs is still fragile and
may produce false positives. Also the test-suite isn't clean yet, one example
is that it fails if a pass drops an NSW bit but it's still present in SCEV's
cached. Cleaning up all those cases will take some time.

llvm-svn: 166786
llvm/include/llvm/Analysis/ScalarEvolution.h
llvm/lib/Analysis/ScalarEvolution.cpp