[all-commits] [llvm/llvm-project] af3c25: [VPlan] Fix iterator invalidation in adjustFixedOr...
Florian Hahn via All-commits
all-commits at lists.llvm.org
Mon Feb 13 05:51:43 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: af3c25dc3d871a7665610a819426c31d5eb17a03
https://github.com/llvm/llvm-project/commit/af3c25dc3d871a7665610a819426c31d5eb17a03
Author: Florian Hahn <flo at fhahn.com>
Date: 2023-02-13 (Mon, 13 Feb 2023)
Changed paths:
M llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp
A llvm/test/Transforms/LoopVectorize/AArch64/first-order-recurrence-fold-tail.ll
Log Message:
-----------
[VPlan] Fix iterator invalidation in adjustFixedOrderRecurrences.
adjustFixedOrderRecurrences may insert instructions after immediately
after the PHI nodes in the block. This invalidates the phis() iterator.
To avoid crashing/accessing invalid recipes, first collect all
first-order recurrence phi recipes.
This should fix a crash reported by @dmgreen after D142589 landed.
More information about the All-commits
mailing list