Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ static cl::opt<bool>
"SimplifyDemandedBits() are consistent"),
cl::Hidden, cl::init(false));

static cl::opt<unsigned> SimplifyDemandedVectorEltsDepthLimit(
"instcombine-simplify-vector-elts-depth",
cl::desc(
"Depth limit when simplifying vector instructions and their operands"),
cl::Hidden, cl::init(10));

/// Check to see if the specified operand of the specified instruction is a
/// constant integer. If so, check to see if there are any bits set in the
/// constant that are not demanded. If so, shrink the constant and return true.
Expand Down Expand Up @@ -1432,7 +1438,7 @@ Value *InstCombinerImpl::SimplifyDemandedVectorElts(Value *V,
}

// Limit search depth.
if (Depth == 10)
if (Depth == SimplifyDemandedVectorEltsDepthLimit)
return nullptr;

if (!AllowMultipleUsers) {
Expand Down
Loading