Skip to content

Commit 7785aeb

Browse files
committed
[VPlan] Fix !all_of nit
1 parent d4e21b4 commit 7785aeb

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2507,9 +2507,10 @@ void VPWidenGEPRecipe::execute(VPTransformState &State) {
25072507
// is vector-typed. Thus, to keep the representation compact, we only use
25082508
// vector-typed operands for loop-varying values.
25092509

2510-
assert(!all_of(operands(), [](VPValue *Op) {
2511-
return Op->isDefinedOutsideLoopRegions();
2512-
}) && "Expected at least one loop-variant operand");
2510+
assert(
2511+
any_of(operands(),
2512+
[](VPValue *Op) { return !Op->isDefinedOutsideLoopRegions(); }) &&
2513+
"Expected at least one loop-variant operand");
25132514

25142515
// If the GEP has at least one loop-varying operand, we are sure to
25152516
// produce a vector of pointers unless VF is scalar.

0 commit comments

Comments
 (0)