[llvm-branch-commits] [llvm] [VPlan] Implement VPlan-based unit-strideness speculation (PR #182595)
Luke Lau via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Tue Aug 25 20:59:30 PDT 2026
================
@@ -5641,33 +5647,34 @@ void VPlanTransforms::multiversionForUnitStridedMemOps(
StridePredicates = StridePredicates.getUnionWith(NewPred, *SE);
- auto ReplaceUsesInVectorLoop = [&](Value *V, const SCEV *ToSCEV) {
+ // Replace the stride and all integral casts derived from it. Some casts
+ // might be defined outside VPlan and modeled as live-ins only, so we need
+ // to process users at the LLVM IR level in order to discover them.
+ auto ReplaceUsesInVectorLoopThroughCastsRecursively =
+ [&](auto &Self, Value *V, const SCEV *ToSCEV) -> void {
----------------
lukel97 wrote:
Probably easier to just extract this out a static function if it needs to be recursive
https://github.com/llvm/llvm-project/pull/182595
More information about the llvm-branch-commits
mailing list