[all-commits] [llvm/llvm-project] 0d0abb: [VPlan] Use ResumePhi to create reduction resume p...

Florian Hahn via All-commits all-commits at lists.llvm.org
Mon Oct 28 12:14:30 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0d0abb351b5fcf49ccc46eba8b7f2a1f353a05a6
      https://github.com/llvm/llvm-project/commit/0d0abb351b5fcf49ccc46eba8b7f2a1f353a05a6
  Author: Florian Hahn <flo at fhahn.com>
  Date:   2024-10-28 (Mon, 28 Oct 2024)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
    M llvm/test/Transforms/LoopVectorize/RISCV/vplan-vp-intrinsics-reduction.ll
    M llvm/test/Transforms/LoopVectorize/first-order-recurrence-sink-replicate-region.ll
    M llvm/test/Transforms/LoopVectorize/vplan-printing.ll

  Log Message:
  -----------
  [VPlan] Use ResumePhi to create reduction resume phis. (#110004)

Use VPInstruction::ResumePhi to create phi nodes for reduction resume
values in the scalar preheader, similar to how ResumePhis are used for
first-order recurrence resume values after 9a5a8731e77.

This allows simplifying createAndCollectMergePhiForReduction to only
collect reduction resume phis when vectorizing epilogue loops and adding
extra incoming edges from the main vector loop. Updating phis for the
epilogue vector loops requires special attention, because additional
incoming values from the bypass blocks need to be added.

PR: https://github.com/llvm/llvm-project/pull/110004



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