summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/IR/OptBisect.cpp19
1 files changed, 13 insertions, 6 deletions
diff --git a/llvm/lib/IR/OptBisect.cpp b/llvm/lib/IR/OptBisect.cpp
index f1c70058fac..dc7dcd2e4a9 100644
--- a/llvm/lib/IR/OptBisect.cpp
+++ b/llvm/lib/IR/OptBisect.cpp
@@ -1,4 +1,4 @@
-//===------- llvm/IR/OptBisect/Bisect.cpp - LLVM Bisect support --------===//
+//===- llvm/IR/OptBisect/Bisect.cpp - LLVM Bisect support -----------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -6,31 +6,38 @@
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
-///
+//
/// \file
/// This file implements support for a bisecting optimizations based on a
/// command line option.
-///
+//
//===----------------------------------------------------------------------===//
#include "llvm/IR/OptBisect.h"
+#include "llvm/ADT/StringRef.h"
+#include "llvm/Analysis/CallGraph.h"
#include "llvm/Analysis/CallGraphSCCPass.h"
-#include "llvm/Analysis/LazyCallGraph.h"
#include "llvm/Analysis/LoopInfo.h"
#include "llvm/Analysis/RegionInfo.h"
+#include "llvm/IR/BasicBlock.h"
+#include "llvm/IR/Function.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/raw_ostream.h"
+#include <cassert>
+#include <limits>
+#include <string>
using namespace llvm;
static cl::opt<int> OptBisectLimit("opt-bisect-limit", cl::Hidden,
- cl::init(INT_MAX), cl::Optional,
+ cl::init(std::numeric_limits<int>::max()),
+ cl::Optional,
cl::desc("Maximum optimization to perform"));
OptBisect::OptBisect() {
- BisectEnabled = OptBisectLimit != INT_MAX;
+ BisectEnabled = OptBisectLimit != std::numeric_limits<int>::max();
}
static void printPassMessage(const StringRef &Name, int PassNum,
OpenPOWER on IntegriCloud