[llvm] [VPlan] Generalize usesScalars using WideInfo (NFCI) (PR #208910)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 13 03:31:38 PDT 2026
================
@@ -56,6 +56,12 @@ static cl::opt<bool> VPlanPrintMetadata(
cl::desc("Controls the printing of recipe metadata when debugging."));
#endif
+bool VPUser::usesScalars(const VPValue *Op) const {
+ assert(is_contained(operands(), Op) && "Op must be an operand of the recipe");
+ VPWideningInfo WideInfo = vputils::getWideningInfo(*cast<VPRecipeBase>(this));
+ return WideInfo.hasSingleScalarOperands() || usesFirstLaneOnly(Op);
----------------
fhahn wrote:
This reads a bit confusing and does not seem NFC, even if operands are not single scalar, he recipe can still use scalars (e.g. replicating VPReplicateRecipe)?
https://github.com/llvm/llvm-project/pull/208910
More information about the llvm-commits
mailing list