LLVM
8.0.1
|
VPRecipeBase is a base class modeling a sequence of one or more output IR instructions. More...
#include "Transforms/Vectorize/VPlan.h"
Public Types | |
using | VPRecipeTy = enum { VPBlendSC, VPBranchOnMaskSC, VPInstructionSC, VPInterleaveSC, VPPredInstPHISC, VPReplicateSC, VPWidenIntOrFpInductionSC, VPWidenMemoryInstructionSC, VPWidenPHISC, VPWidenSC, } |
An enumeration for keeping track of the concrete subclass of VPRecipeBase that is actually instantiated. More... | |
Public Member Functions | |
VPRecipeBase (const unsigned char SC) | |
virtual | ~VPRecipeBase ()=default |
unsigned | getVPRecipeID () const |
VPBasicBlock * | getParent () |
const VPBasicBlock * | getParent () const |
virtual void | execute (struct VPTransformState &State)=0 |
The method which generates the output IR instructions that correspond to this VPRecipe, thereby "executing" the VPlan. More... | |
virtual void | print (raw_ostream &O, const Twine &Indent) const =0 |
Each recipe prints itself. More... | |
void | insertBefore (VPRecipeBase *InsertPos) |
Insert an unlinked recipe into a basic block immediately before the specified recipe. More... | |
iplist< VPRecipeBase >::iterator | eraseFromParent () |
This method unlinks 'this' from the containing basic block and deletes it. More... | |
Public Member Functions inherited from llvm::ilist_node_with_parent< VPRecipeBase, VPBasicBlock > | |
VPRecipeBase * | getPrevNode () |
const VPRecipeBase * | getPrevNode () const |
Get the previous node, or nullptr for the list head. More... | |
VPRecipeBase * | getNextNode () |
Get the next node, or nullptr for the list tail. More... | |
const VPRecipeBase * | getNextNode () const |
Get the next node, or nullptr for the list tail. More... | |
Public Member Functions inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type > | |
self_iterator | getIterator () |
const_self_iterator | getIterator () const |
reverse_self_iterator | getReverseIterator () |
const_reverse_self_iterator | getReverseIterator () const |
bool | isSentinel () const |
Check whether this is the sentinel node. More... | |
Additional Inherited Members | |
Protected Types inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type > | |
using | self_iterator = ilist_iterator< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type, false, false > |
using | const_self_iterator = ilist_iterator< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type, false, true > |
using | reverse_self_iterator = ilist_iterator< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type, true, false > |
using | const_reverse_self_iterator = ilist_iterator< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type, true, true > |
Protected Member Functions inherited from llvm::ilist_node_with_parent< VPRecipeBase, VPBasicBlock > | |
ilist_node_with_parent ()=default | |
Protected Member Functions inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< VPRecipeBase, Options... >::type > | |
ilist_node_impl ()=default | |
VPRecipeBase is a base class modeling a sequence of one or more output IR instructions.
using llvm::VPRecipeBase::VPRecipeTy = enum { VPBlendSC, VPBranchOnMaskSC, VPInstructionSC, VPInterleaveSC, VPPredInstPHISC, VPReplicateSC, VPWidenIntOrFpInductionSC, VPWidenMemoryInstructionSC, VPWidenPHISC, VPWidenSC, } |
An enumeration for keeping track of the concrete subclass of VPRecipeBase that is actually instantiated.
Values of this enumeration are kept in the SubclassID field of the VPRecipeBase objects. They are used for concrete type identification.
|
virtualdefault |
iplist< VPRecipeBase >::iterator VPRecipeBase::eraseFromParent | ( | ) |
This method unlinks 'this' from the containing basic block and deletes it.
Definition at line 283 of file VPlan.cpp.
References B, llvm::VPTransformState::Builder, llvm::IRBuilder< T, Inserter >::CreateBinOp(), llvm::IRBuilder< T, Inserter >::CreateICmpULE(), llvm::IRBuilder< T, Inserter >::CreateNot(), llvm::VPTransformState::get(), getOpcode(), llvm::VPBlockBase::getParent(), llvm::VPInstruction::ICmpULE, llvm::Instruction::isBinaryOp(), llvm_unreachable, llvm::VPInstruction::Not, and llvm::VPTransformState::set().
Referenced by llvm::VPlanHCFGTransforms::VPInstructionsToVPRecipes().
|
pure virtual |
The method which generates the output IR instructions that correspond to this VPRecipe, thereby "executing" the VPlan.
Implemented in llvm::VPWidenMemoryInstructionRecipe, llvm::VPPredInstPHIRecipe, llvm::VPBranchOnMaskRecipe, llvm::VPReplicateRecipe, llvm::VPInterleaveRecipe, llvm::VPBlendRecipe, llvm::VPWidenPHIRecipe, llvm::VPWidenIntOrFpInductionRecipe, llvm::VPWidenRecipe, and llvm::VPInstruction.
|
inline |
Definition at line 587 of file VPlan.h.
Referenced by insertBefore().
|
inline |
Definition at line 588 of file VPlan.h.
References Indent, llvm::RISCVFenceField::O, and print().
|
inline |
Definition at line 584 of file VPlan.h.
Referenced by llvm::VPInstruction::classof(), llvm::VPWidenRecipe::classof(), llvm::VPWidenIntOrFpInductionRecipe::classof(), llvm::VPWidenPHIRecipe::classof(), llvm::VPBlendRecipe::classof(), llvm::VPInterleaveRecipe::classof(), llvm::VPReplicateRecipe::classof(), llvm::VPBranchOnMaskRecipe::classof(), llvm::VPPredInstPHIRecipe::classof(), and llvm::VPWidenMemoryInstructionRecipe::classof().
void VPRecipeBase::insertBefore | ( | VPRecipeBase * | InsertPos | ) |
Insert an unlinked recipe into a basic block immediately before the specified recipe.
Definition at line 278 of file VPlan.cpp.
References llvm::ilist_node_impl< OptionsT >::getIterator(), and getParent().
Referenced by llvm::VPlanHCFGTransforms::VPInstructionsToVPRecipes().
|
pure virtual |
Each recipe prints itself.
Implemented in llvm::VPWidenMemoryInstructionRecipe, llvm::VPPredInstPHIRecipe, llvm::VPBranchOnMaskRecipe, llvm::VPReplicateRecipe, llvm::VPInterleaveRecipe, llvm::VPBlendRecipe, llvm::VPWidenPHIRecipe, llvm::VPWidenIntOrFpInductionRecipe, llvm::VPWidenRecipe, and llvm::VPInstruction.