[ValueTracking] "constant fold" an experimental hidden option

llvm-svn: 262648
This commit is contained in:
Philip Reames 2016-03-03 19:50:32 +00:00
parent 4e442d75e5
commit b7270446cf
1 changed files with 0 additions and 7 deletions

View File

@ -50,10 +50,6 @@ const unsigned MaxDepth = 6;
static cl::opt<unsigned> DomConditionsMaxUses("dom-conditions-max-uses", static cl::opt<unsigned> DomConditionsMaxUses("dom-conditions-max-uses",
cl::Hidden, cl::init(20)); cl::Hidden, cl::init(20));
// If true, don't consider only compares whose only use is a branch.
static cl::opt<bool> DomConditionsSingleCmpUse("dom-conditions-single-cmp-use",
cl::Hidden, cl::init(false));
/// Returns the bitwidth of the given scalar or pointer type (if unknown returns /// Returns the bitwidth of the given scalar or pointer type (if unknown returns
/// 0). For vector types, returns the element type's bitwidth. /// 0). For vector types, returns the element type's bitwidth.
static unsigned getBitWidth(Type *Ty, const DataLayout &DL) { static unsigned getBitWidth(Type *Ty, const DataLayout &DL) {
@ -3073,9 +3069,6 @@ static bool isKnownNonNullFromDominatingCondition(const Value *V,
if (!Cmp) if (!Cmp)
continue; continue;
if (DomConditionsSingleCmpUse && !Cmp->hasOneUse())
continue;
for (auto *CmpU : Cmp->users()) { for (auto *CmpU : Cmp->users()) {
const BranchInst *BI = dyn_cast<BranchInst>(CmpU); const BranchInst *BI = dyn_cast<BranchInst>(CmpU);
if (!BI) if (!BI)