Simplify std::all_of predicate (to one line) by using llvm::all_of. NFCI.

llvm-svn: 270747
This commit is contained in:
Simon Pilgrim 2016-05-25 20:13:39 +00:00
parent 84f0562064
commit 0a6b95a60a
1 changed files with 1 additions and 3 deletions

View File

@ -13068,9 +13068,7 @@ SDValue DAGCombiner::visitCONCAT_VECTORS(SDNode *N) {
auto IsBuildVectorOrUndef = [](const SDValue &Op) {
return ISD::UNDEF == Op.getOpcode() || ISD::BUILD_VECTOR == Op.getOpcode();
};
bool AllBuildVectorsOrUndefs =
std::all_of(N->op_begin(), N->op_end(), IsBuildVectorOrUndef);
if (AllBuildVectorsOrUndefs) {
if (llvm::all_of(N->ops(), IsBuildVectorOrUndef)) {
SmallVector<SDValue, 8> Opnds;
EVT SVT = VT.getScalarType();