111 void ClassifyLoop(
const LoopConstRef loop,
const size_t parallel_degree);
135 unsigned int Transform(
const unsigned int tree_node_index,
const size_t parallel_degree,
const size_t scalar_index,
136 std::list<tree_nodeRef>& new_stmt_list, std::vector<tree_nodeRef>& new_phi_list);
bool HasToBeExecuted() const override
Check if this step has actually to be executed.
void ClassifyTreeNode(const unsigned int loop_id, const tree_nodeConstRef tree_node)
Classify a statement.
This struct specifies the field bloc (basic block).
CustomUnorderedMap< unsigned int, CustomUnorderedMapStable< size_t, unsigned int > > scalar_to_scalar
Map between scalar tree node and versioned scalar tree node.
void SetPredication()
Set predicate of predicated instructions.
CustomMap< unsigned int, SimdLoop > simd_loop_type
Loop classification.
bool LookForScalar(const tree_nodeConstRef tree_node)
Check recursively if at least an ssa operand is defined an operation outside simd outer loop...
RelationshipType
The relationship type.
This class manages the tree structures extracted from the raw file.
DesignFlowStep_Status InternalExec() override
Restructures the unstructured code.
CONSTREF_FORWARD_DECL(Loop)
CustomMap< unsigned int, bool > basic_block_divergence
Basic block classification: if value is true, the basic block can be executed or not in parallel inst...
CustomOrderedMap< T, U > CustomMap
Vectorize(const application_managerRef AppM, unsigned int function_id, const DesignFlowManagerConstRef design_flow_manager, const ParameterConstRef parameters)
Constructor.
enum Transformation { NONE, COND_CON, COND_DIV, INC, INIT, SCALAR, SIMD, } Transformation
Enum used to classify the statement according to the required transformation.
This class contains the base representation for a generic frontend flow step which works on a single ...
absl::flat_hash_map< T, U, Hash, Eq, Alloc > CustomUnorderedMapUnstable
redefinition of map to manage ordered/unordered structures
Abstract pure class for the tree structure.
CustomMap< unsigned int, integer_cst_t > iv_increment
The increment of induction variables; id is the index of the ssa name defined in the init gimple...
unsigned int DuplicateIncrement(const unsigned int loop_id, const tree_nodeRef statement)
Duplicate increment statement and update uses of defined variable when necessary. ...
absl::flat_hash_map< T, U, Hash, Eq, Alloc > CustomUnorderedMap
CustomUnorderedMapUnstable< unsigned int, unsigned int > scalar_to_vector
Map between scalar tree node and vector tree node.
void ClassifyLoop(const LoopConstRef loop, const size_t parallel_degree)
Classify a loop.
const Wrefcount< const DesignFlowManager > design_flow_manager
The design flow manager.
CustomMap< unsigned int, size_t > loop_parallel_degree
Loop parallel degree.
~Vectorize() override
Destructor.
unsigned int Transform(const unsigned int tree_node_index, const size_t parallel_degree, const size_t scalar_index, std::list< tree_nodeRef > &new_stmt_list, std::vector< tree_nodeRef > &new_phi_list)
Transform a tree node.
const ParameterConstRef parameters
Set of input parameters.
DesignFlowStep_Status
The status of a step.
const tree_manipulationRef tree_man
The tree_manipulation.
void AddGuards()
Add the guards for predicated operations.
CustomMap< unsigned int, tree_nodeRef > guards
The guards for each basic block.
const unsigned int function_id
The index of the function to be analyzed.
const application_managerRef AppM
The application manager.
Template borrowed from the ANTLR library by Terence Parr (http://www.jGuru.com - Software rights: htt...
const CustomUnorderedSet< std::pair< FrontendFlowStepType, FunctionRelationship > > ComputeFrontendRelationships(const DesignFlowStep::RelationshipType relationship_type) const override
Return the set of analyses in relationship with this design step.
enum { SIMD_NONE, SIMD_INNER, SIMD_OUTER } SimdLoop
Enum used to classify the loop according to the required transformation.
CustomMap< unsigned int, Transformation > transformations
Statement classification.
void FixPhis()
Fix the phis to consider implicitly predicated operations.
This class creates a layer to add nodes and to manipulate the tree_nodes manager. ...
const tree_managerRef TM
The tree manager.