summaryrefslogtreecommitdiff
path: root/llvm/unittests/Transforms/Vectorize/VPDomTreeTest.cpp
AgeCommit message (Collapse)Author
2025-10-21[VPlan] Clarify naming for helpers to create loop&replicate regions (NFC)Florian Hahn
Split off to clarify naming, as suggested in https://github.com/llvm/llvm-project/pull/156262.
2025-10-13[VPlan] Strip VPDT's default constructor (NFC) (#162692)Ramkumar Ramachandra
2024-12-30[VPlan] Manage created blocks directly in VPlan. (NFC) (#120918)Florian Hahn
This patch changes the way blocks are managed by VPlan. Previously all blocks reachable from entry would be cleaned up when a VPlan is destroyed. With this patch, each VPlan keeps track of blocks created for it in a list and this list is then used to delete all blocks in the list when the VPlan is destroyed. To do so, block creation is funneled through helpers in directly in VPlan. The main advantage of doing so is it simplifies CFG transformations, as those do not have to take care of deleting any blocks, just adjusting the CFG. This helps to simplify https://github.com/llvm/llvm-project/pull/108378 and https://github.com/llvm/llvm-project/pull/106748. This also simplifies handling of 'immutable' blocks a VPlan holds references to, which at the moment only include the scalar header block. PR: https://github.com/llvm/llvm-project/pull/120918
2024-12-27[VPlan] Always create initial blocks in constructor (NFC).Florian Hahn
Update C++ unit tests to use VPlanTestBase to construct initial VPlan, using a constructor that creates the VP blocks directly in the constructor. Split off from and in preparation for https://github.com/llvm/llvm-project/pull/120918.
2024-12-18[VPlan] Don't use VPlan ctor taking trip count in most unit tests (NFC).Florian Hahn
Update tests to use constructor not passing a trip count VPValue. The tests don't need that and are simpler as a result.
2024-12-17[VPlan] Remove legacy VPlan() constructors (NFC).Florian Hahn
The constructors were retained to reduce the diff during transition. Remove them now.
2024-11-01[VPlan] Don't leak ScalarHeader BasicBlock in unit tests.Florian Hahn
2024-11-01[VPlan] Connect scalar header to VPlan CFG in unit tests.Florian Hahn
This ensures the VPIRBasicBlocks are deleted when the VPlan is destroyed. Fixes a buildbot failure with ASAN, including https://lab.llvm.org/buildbot/#/builders/52/builds/3368
2024-10-31[VPlan] Introduce scalar loop header in plan, remove VPLiveOut. (#109975)Florian Hahn
Update VPlan to include the scalar loop header. This allows retiring VPLiveOut, as the remaining live-outs can now be handled by adding operands to the wrapped phis in the scalar loop header. Note that the current version only includes the scalar loop header, no other loop blocks and also does not wrap it in a region block. PR: https://github.com/llvm/llvm-project/pull/109975
2023-05-04[VPlan] Introduce new entry block to VPlan for early SCEV expansion.Florian Hahn
This patch adds a new preheader block the VPlan to place SCEV expansions expansions like the trip count. This preheader block is disconnected at the moment, as the bypass blocks of the skeleton are not yet modeled in VPlan. The preheader block is executed before skeleton creation, so the SCEV expansion results can be used during skeleton creation. At the moment, the trip count expression and induction steps are expanded in the new preheader. The remainder of SCEV expansions will be moved gradually in the future. D147965 will update skeleton creation to use the steps expanded in the pre-header to fix #58811. Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D147964
2023-04-28[VPlan] Turn Plan entry node into VPBasicBlock (NFCI).Florian Hahn
The entry to the plan is the preheader of the vector loop and guaranteed to be a VPBasicBlock. Make sure this is the case by adjusting the type. Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D149005
2023-01-23[VPlan] Switch default graph traits to be recursive, update VPDomTree.Florian Hahn
This updates the GraphTraits specialization for VPBlockBase to recurse through VPRegionBlocks. This in turn enables using VPDominatorTree to query dominance between any block in a plan. This should enable additional use cases, including improvements to def-use verification and porting IR-based transforms that rely on the dominator tree. Specifically, this change means that for regions, the entry and exit blocks dominate the successors of the region. Depends on D140512 and D142162. Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D140513
2023-01-20[VPlan] Add initial VPDT test. (NFC)Florian Hahn