LLVM  14.0.0git
VPlanTransforms.h
Go to the documentation of this file.
1 //===- VPlanTransforms.h - Utility VPlan to VPlan transforms --------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 ///
9 /// \file
10 /// This file provides utility VPlan to VPlan transformations.
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_TRANSFORMS_VECTORIZE_VPLANTRANSFORMS_H
14 #define LLVM_TRANSFORMS_VECTORIZE_VPLANTRANSFORMS_H
15 
16 #include "VPlan.h"
18 
19 namespace llvm {
20 
21 class Instruction;
22 class ScalarEvolution;
23 
25  /// Replaces the VPInstructions in \p Plan with corresponding
26  /// widen recipes.
27  static void VPInstructionsToVPRecipes(
28  Loop *OrigLoop, VPlanPtr &Plan,
30  SmallPtrSetImpl<Instruction *> &DeadInstructions, ScalarEvolution &SE);
31 
32  static bool sinkScalarOperands(VPlan &Plan);
33 
34  static bool mergeReplicateRegions(VPlan &Plan);
35 };
36 
37 } // namespace llvm
38 
39 #endif // LLVM_TRANSFORMS_VECTORIZE_VPLANTRANSFORMS_H
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AllocatorList.h:23
llvm::Loop
Represents a single loop in the control flow graph.
Definition: LoopInfo.h:530
llvm::ScalarEvolution
The main scalar evolution driver.
Definition: ScalarEvolution.h:460
llvm::VPlanPtr
std::unique_ptr< VPlan > VPlanPtr
Definition: VPlan.h:93
llvm::MapVector< PHINode *, InductionDescriptor >
VPlan.h
llvm::VPlanTransforms::sinkScalarOperands
static bool sinkScalarOperands(VPlan &Plan)
Definition: VPlanTransforms.cpp:102
llvm::VPlanTransforms::VPInstructionsToVPRecipes
static void VPInstructionsToVPRecipes(Loop *OrigLoop, VPlanPtr &Plan, LoopVectorizationLegality::InductionList &Inductions, SmallPtrSetImpl< Instruction * > &DeadInstructions, ScalarEvolution &SE)
Replaces the VPInstructions in Plan with corresponding widen recipes.
Definition: VPlanTransforms.cpp:19
LoopVectorizationLegality.h
llvm::VPlanTransforms
Definition: VPlanTransforms.h:24
llvm::SmallPtrSetImpl< Instruction * >
llvm::VPlanTransforms::mergeReplicateRegions
static bool mergeReplicateRegions(VPlan &Plan)
Definition: VPlanTransforms.cpp:214
llvm::VPlan
VPlan models a candidate for vectorization, encoding various decisions take to produce efficient outp...
Definition: VPlan.h:2089