This is an archive of the discontinued LLVM Phabricator instance.

Add RecursionChecker for finding infinite recursion
Needs ReviewPublic

Authored by k-wisniewski on Nov 24 2016, 3:46 AM.

Details

Summary

This patch adds RecursionChecker for finding infinite recursion. I have refactored the checker quite thoroughly since the last time I posted it - it should now support ObjC methods as well. I have fixed several issues pointed out in the previous version too. My plan for now is to have it tested on some real code bases to check how useful it is in practice and evaluate its performance. I will also implement some heurestics to eliminate excesive false positives/negatives and evaluate them.

BTW. as I'm a complete newbie in Objective-C - could you please help me with some interesting unit test cases for this checker?
Thanks in advance!

Diff Detail

Event Timeline

k-wisniewski retitled this revision from to Add RecursionChecker for finding infinite recursion.
k-wisniewski updated this object.
k-wisniewski added a subscriber: cfe-commits.
zaks.anna edited edge metadata.Mar 6 2017, 9:58 AM

This is waiting for a resolution on a CallEvent API patch as described in https://reviews.llvm.org/D27091.

This is blocked on https://reviews.llvm.org/D27091.

lib/StaticAnalyzer/Checkers/RecursionChecker.cpp
29