[all-commits] [llvm/llvm-project] ef7e03: [VPlan] Limit ExtractLastElem fold to recipes guar...

Florian Hahn via All-commits all-commits at lists.llvm.org
Sat Sep 13 10:16:30 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: ef7e03a2d1571e3c651fa9ccd205dbacf1a103c8
      https://github.com/llvm/llvm-project/commit/ef7e03a2d1571e3c651fa9ccd205dbacf1a103c8
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2025-09-13 (Sat, 13 Sep 2025)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp
    A llvm/test/Transforms/LoopVectorize/first-order-recurrence-with-uniform-ops.ll
    M llvm/test/Transforms/LoopVectorize/first-order-recurrence.ll

  Log Message:
  -----------
  [VPlan] Limit ExtractLastElem fold to recipes guaranteed single-scalar.

vputils::isSingleScalar(A) may return true to recipes that produce only
a single scalar value, but they could still end up as vector
instruction, because the recipe could not be converted to a
single-scalar VPInstruction/VPReplicateRecipe.

For now, only apply the fold for recipes guaranteed to produce a single
value, i.e. single-scalar VPInstructions and VPReplicateRecipes.

Fixes https://github.com/llvm/llvm-project/issues/158319.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list