[analyzer] Bound the size of the functions being inlined + provide

command line options for inlining tuning.

This adds the option for stack depth bound as well as function size
bound. 

+ minor doxygenification

llvm-svn: 151930
This commit is contained in:
Anna Zaks
2012-03-02 19:05:03 +00:00
parent 242d9838c6
commit 265087721a
8 changed files with 60 additions and 21 deletions

View File

@@ -1047,6 +1047,12 @@ static bool ParseAnalyzerArgs(AnalyzerOptions &Opts, ArgList &Args,
if (Args.hasArg(OPT_analyzer_inline_call))
Opts.InlineCall = 1;
Opts.PrintStats = Args.hasArg(OPT_analyzer_stats);
Opts.InlineMaxStackDepth =
Args.getLastArgIntValue(OPT_analyzer_inline_max_stack_depth,
Opts.InlineMaxStackDepth, Diags);
Opts.InlineMaxFunctionSize =
Args.getLastArgIntValue(OPT_analyzer_inline_max_function_size,
Opts.InlineMaxFunctionSize, Diags);
Opts.CheckersControlList.clear();
for (arg_iterator it = Args.filtered_begin(OPT_analyzer_checker,