|
docc 0.8.3 (0d44999b)
C++ API Reference
|
Represents a parallel map loop with configurable scheduling. More...
#include <sdfg/structured_control_flow/map.h>
Public Member Functions | |
| Map (const Map &node)=delete | |
| Map & | operator= (const Map &)=delete |
| ElementType | type_id () const override |
| Returns the type of the element. | |
| bool | accept (visitor::ActualStructuredSDFGVisitor &visitor) override |
| void | validate (const Function &function) const override |
| Validates the element. | |
| Public Member Functions inherited from sdfg::structured_control_flow::StructuredLoop | |
| virtual | ~StructuredLoop ()=default |
| StructuredLoop (const StructuredLoop &node)=delete | |
| StructuredLoop & | operator= (const StructuredLoop &)=delete |
| void | validate (const Function &function) const override |
| Validates the element. | |
| const symbolic::Symbol | indvar () const |
| Get the induction variable (loop counter) symbol. | |
| const symbolic::Expression | init () const |
| Get the initialization expression for the induction variable. | |
| const symbolic::Expression | update () const |
| Get the update expression for the induction variable. | |
| const symbolic::Condition | condition () const |
| Get the loop continuation condition. | |
| Sequence & | root () const |
| Access the loop body sequence. | |
| const ScheduleType & | schedule_type () const |
| Get the scheduling strategy for this Map. | |
| void | replace (const symbolic::Expression old_expression, const symbolic::Expression new_expression) override |
| Replace occurrences of an expression in loop parameters and body. | |
| void | replace (const symbolic::ExpressionMapping &replacements) override |
| symbolic::Integer | stride () const |
| Describes the stride of a loop's update as a constant. | |
| bool | is_contiguous () const |
| Checks if the loop has a positive unit stride (i.e., update is indvar + 1). | |
| bool | is_monotonic () const |
| Checks if the loop is monotonic (i.e., stride is a positive integer). | |
| symbolic::Expression | canonical_bound () const |
| Describes the bound of a loop as a closed-form expression. | |
| symbolic::Expression | canonical_bound_upper () const |
| Describes the upper bound of a loop (for positive stride). | |
| symbolic::Expression | canonical_bound_lower () const |
| Describes the lower bound of a loop (for negative stride). | |
| symbolic::Expression | num_iterations () const |
| Describes the number of iterations of a loop as a closed-form expression. | |
| symbolic::Expression | num_iterations_approx () const |
| Overapproximated (upper-bound) number of iterations. | |
| bool | is_loop_normal_form () const |
| Checks if the loop is in a normal form. | |
| Public Member Functions inherited from sdfg::structured_control_flow::ControlFlowNode | |
| virtual | ~ControlFlowNode ()=default |
| ControlFlowNode * | get_parent () |
| const ControlFlowNode * | get_parent () const |
| ControlFlowNode (const ControlFlowNode &node)=delete | |
| ControlFlowNode & | operator= (const ControlFlowNode &)=delete |
| Public Member Functions inherited from sdfg::Element | |
| Element (size_t element_id, const DebugInfo &debug_info) | |
| virtual | ~Element ()=default |
| size_t | element_id () const |
| const DebugInfo & | debug_info () const |
| void | set_debug_info (const DebugInfo &debug_info) |
| void | add_metadata (const std::string &key, const std::string &value) |
| void | remove_metadata (const std::string &key) |
| const std::string & | metadata (const std::string &key) const |
| const std::string * | metadata_if_exists (const std::string &key) const |
| const std::unordered_map< std::string, std::string > & | metadata () const |
| std::string_view | element_type () const |
| Returns the type of the element as a human-readable string. | |
Static Public Member Functions | |
| static bool | classof (const Element &element) |
| Static Public Member Functions inherited from sdfg::structured_control_flow::StructuredLoop | |
| static bool | classof (const Element &element) |
LLVM-style RTTI predicate: true if element is a StructuredLoop. | |
| Static Public Member Functions inherited from sdfg::structured_control_flow::ControlFlowNode | |
| static bool | classof (const Element &element) |
LLVM-style RTTI predicate: true if element is a ControlFlowNode. | |
| static std::vector< ControlFlowNode * > | parent_chain (ControlFlowNode &child) |
Friends | |
| class | sdfg::builder::StructuredSDFGBuilder |
Represents a parallel map loop with configurable scheduling.
A Map is a special type of structured loop that can be executed in parallel. Unlike For loops which execute sequentially, Map loops explicitly indicate that iterations are independent and can be distributed across parallel execution units (threads, cores, etc.).
Maps support different scheduling strategies:
Example:
Maps are commonly used for:
|
delete |
|
overridevirtual |
Implements sdfg::structured_control_flow::ControlFlowNode.
|
inlinestatic |
|
delete |
|
inlineoverridevirtual |
Returns the type of the element.
Implements sdfg::Element.
|
overridevirtual |
Validates the element.
| InvalidSDFGException | if the element is invalid |
Implements sdfg::Element.
|
friend |