diff options
author | Tom Care <tcare@apple.com> | 2010-07-06 21:43:29 +0000 |
---|---|---|
committer | Tom Care <tcare@apple.com> | 2010-07-06 21:43:29 +0000 |
commit | 3ff08a8e76eeb25ceeed2c7461eccd388f996985 (patch) | |
tree | a9ee816fe14fa19a856f4a5c1debb30d5a6dcdcc /llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | |
parent | 4c1ca2903984f760a2f3de2d51c8c9ba3e669d54 (diff) | |
download | bcm5719-llvm-3ff08a8e76eeb25ceeed2c7461eccd388f996985.tar.gz bcm5719-llvm-3ff08a8e76eeb25ceeed2c7461eccd388f996985.zip |
Added a path-sensitive idempotent operation checker (-analyzer-idempotent-operation). Finds idempotent and/or tautological operations in a path sensitive context, flagging operations that have no effect or a predictable effect.
Example:
{
int a = 1;
int b = 5;
int c = b / a; // a is 1 on all paths
}
- New IdempotentOperationChecker class
- Moved recursive Stmt functions in r107675 to IdempotentOperationChecker
- Minor refactoring of SVal to allow checking for any integer
- Added command line option for check
- Added basic test cases
llvm-svn: 107706
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp')
0 files changed, 0 insertions, 0 deletions