summaryrefslogtreecommitdiff
path: root/lib/Analysis
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2017-12-01 00:53:10 +0000
committerZachary Turner <zturner@google.com>2017-12-01 00:53:10 +0000
commit9a4e15cb762e14a1725847c26b5104845b0f22b2 (patch)
treeeaf71bd906ffe411496d3b0becd7344af2ffa33b /lib/Analysis
parent2a6c2bd504e7614d02e029b4e5c447a7638a5467 (diff)
Mark all library options as hidden.
These command line options are not intended for public use, and often don't even make sense in the context of a particular tool anyway. About 90% of them are already hidden, but when people add new options they forget to hide them, so if you were to make a brand new tool today, link against one of LLVM's libraries, and run tool -help you would get a bunch of junk that doesn't make sense for the tool you're writing. This patch hides these options. The real solution is to not have libraries defining command line options, but that's a much larger effort and not something I'm prepared to take on. Differential Revision: https://reviews.llvm.org/D40674 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@319505 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis')
-rw-r--r--lib/Analysis/LoopInfo.cpp2
-rw-r--r--lib/Analysis/ObjCARCAnalysisUtils.cpp8
-rw-r--r--lib/Analysis/ScalarEvolution.cpp8
-rw-r--r--lib/Analysis/ScopedNoAliasAA.cpp2
-rw-r--r--lib/Analysis/TypeBasedAliasAnalysis.cpp2
5 files changed, 10 insertions, 12 deletions
diff --git a/lib/Analysis/LoopInfo.cpp b/lib/Analysis/LoopInfo.cpp
index 9a223df9394..dce66fd3d96 100644
--- a/lib/Analysis/LoopInfo.cpp
+++ b/lib/Analysis/LoopInfo.cpp
@@ -47,7 +47,7 @@ bool llvm::VerifyLoopInfo = false;
#endif
static cl::opt<bool, true>
VerifyLoopInfoX("verify-loop-info", cl::location(VerifyLoopInfo),
- cl::desc("Verify loop info (time consuming)"));
+ cl::Hidden, cl::desc("Verify loop info (time consuming)"));
//===----------------------------------------------------------------------===//
// Loop implementation
diff --git a/lib/Analysis/ObjCARCAnalysisUtils.cpp b/lib/Analysis/ObjCARCAnalysisUtils.cpp
index e3e74aa249d..55335f3a7cb 100644
--- a/lib/Analysis/ObjCARCAnalysisUtils.cpp
+++ b/lib/Analysis/ObjCARCAnalysisUtils.cpp
@@ -21,8 +21,6 @@ using namespace llvm::objcarc;
/// \brief A handy option to enable/disable all ARC Optimizations.
bool llvm::objcarc::EnableARCOpts;
-static cl::opt<bool, true>
-EnableARCOptimizations("enable-objc-arc-opts",
- cl::desc("enable/disable all ARC Optimizations"),
- cl::location(EnableARCOpts),
- cl::init(true));
+static cl::opt<bool, true> EnableARCOptimizations(
+ "enable-objc-arc-opts", cl::desc("enable/disable all ARC Optimizations"),
+ cl::location(EnableARCOpts), cl::init(true), cl::Hidden);
diff --git a/lib/Analysis/ScalarEvolution.cpp b/lib/Analysis/ScalarEvolution.cpp
index 25e3b0c3585..e598f2005c3 100644
--- a/lib/Analysis/ScalarEvolution.cpp
+++ b/lib/Analysis/ScalarEvolution.cpp
@@ -153,11 +153,11 @@ MaxBruteForceIterations("scalar-evolution-max-iterations", cl::ReallyHidden,
cl::init(100));
// FIXME: Enable this with EXPENSIVE_CHECKS when the test suite is clean.
+static cl::opt<bool> VerifySCEV(
+ "verify-scev", cl::Hidden,
+ cl::desc("Verify ScalarEvolution's backedge taken counts (slow)"));
static cl::opt<bool>
-VerifySCEV("verify-scev",
- cl::desc("Verify ScalarEvolution's backedge taken counts (slow)"));
-static cl::opt<bool>
- VerifySCEVMap("verify-scev-maps",
+ VerifySCEVMap("verify-scev-maps", cl::Hidden,
cl::desc("Verify no dangling value in ScalarEvolution's "
"ExprValueMap (slow)"));
diff --git a/lib/Analysis/ScopedNoAliasAA.cpp b/lib/Analysis/ScopedNoAliasAA.cpp
index ada053cfc16..b97b08ad074 100644
--- a/lib/Analysis/ScopedNoAliasAA.cpp
+++ b/lib/Analysis/ScopedNoAliasAA.cpp
@@ -48,7 +48,7 @@ using namespace llvm;
// can also be achieved by stripping the associated metadata tags from IR, but
// this option is sometimes more convenient.
static cl::opt<bool> EnableScopedNoAlias("enable-scoped-noalias",
- cl::init(true));
+ cl::init(true), cl::Hidden);
namespace {
diff --git a/lib/Analysis/TypeBasedAliasAnalysis.cpp b/lib/Analysis/TypeBasedAliasAnalysis.cpp
index 1e36e314b86..2b21b685c7a 100644
--- a/lib/Analysis/TypeBasedAliasAnalysis.cpp
+++ b/lib/Analysis/TypeBasedAliasAnalysis.cpp
@@ -142,7 +142,7 @@ using namespace llvm;
// A handy option for disabling TBAA functionality. The same effect can also be
// achieved by stripping the !tbaa tags from IR, but this option is sometimes
// more convenient.
-static cl::opt<bool> EnableTBAA("enable-tbaa", cl::init(true));
+static cl::opt<bool> EnableTBAA("enable-tbaa", cl::init(true), cl::Hidden);
namespace {