From: Matthew Simpson Date: Thu, 11 Aug 2016 15:28:45 +0000 (+0000) Subject: [SLP] Make RecursionMaxDepth a command line option (NFC) X-Git-Tag: llvmorg-4.0.0-rc1~12752 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3f69195b9e43b76a35ae8c8d86cf51ea942a6b0e;p=platform%2Fupstream%2Fllvm.git [SLP] Make RecursionMaxDepth a command line option (NFC) llvm-svn: 278343 --- diff --git a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp index 05ffa06..fb02354 100644 --- a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp +++ b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp @@ -82,8 +82,9 @@ static cl::opt MinVectorRegSizeOption( "slp-min-reg-size", cl::init(128), cl::Hidden, cl::desc("Attempt to vectorize for this register size in bits")); -// FIXME: Set this via cl::opt to allow overriding. -static const unsigned RecursionMaxDepth = 12; +static cl::opt RecursionMaxDepth( + "slp-recursion-max-depth", cl::init(12), cl::Hidden, + cl::desc("Limit the recursion depth when building a vectorizable tree")); // Limit the number of alias checks. The limit is chosen so that // it has no negative effect on the llvm benchmarks.