|
ttg 1.0.0-alpha
Template Task Graph (TTG): flowgraph-based programming model for high-performance distributed-memory algorithms
|
#include <terminal.h>
Public Types | |
| using | base_type = InTerminalBase< keyT > |
| typedef valueT | value_type |
| typedef keyT | key_type |
| using | edge_type = Edge< keyT, valueT > |
| using | send_callback_type = meta::detail::send_callback_t< keyT, std::decay_t< valueT > > |
| using | move_callback_type = meta::detail::move_callback_t< keyT, std::decay_t< valueT > > |
| using | broadcast_callback_type = meta::detail::broadcast_callback_t< keyT, std::decay_t< valueT > > |
| using | setsize_callback_type = typename base_type::setsize_callback_type |
| using | finalize_callback_type = typename base_type::finalize_callback_type |
| using | prepare_send_callback_type = meta::detail::prepare_send_callback_t< keyT, std::decay_t< valueT > > |
Public Types inherited from ttg::InTerminalBase< keyT > | |
| typedef keyT | key_type |
| using | setsize_callback_type = meta::detail::setsize_callback_t< keyT > |
| using | finalize_callback_type = meta::detail::finalize_callback_t< keyT > |
Public Types inherited from ttg::TerminalBase | |
| enum class | Type { Write , Read , Consume } |
| describes the terminal type More... | |
Public Member Functions | |
| In () | |
| Default constructor of an Input Terminal. | |
| void | set_callback (const send_callback_type &send_callback, const move_callback_type &move_callback, const broadcast_callback_type &bcast_callback=broadcast_callback_type{}, const setsize_callback_type &setsize_callback=setsize_callback_type{}, const finalize_callback_type &finalize_callback=finalize_callback_type{}, const prepare_send_callback_type &prepare_send_callback=prepare_send_callback_type{}) |
| template<typename Key = keyT, typename Value = valueT> | |
| std::enable_if_t< meta::is_none_void_v< Key, Value >, void > | send (const Key &key, Value &&value) |
| template<typename Key = keyT> | |
| std::enable_if_t<!meta::is_void_v< Key >, void > | sendk (const Key &key) |
| template<typename Value = valueT> | |
| std::enable_if_t<!meta::is_void_v< Value >, void > | sendv (Value &&value) |
| void | send () |
| template<typename rangeT , typename Value > | |
| std::enable_if_t<!meta::is_void_v< Value >, void > | broadcast (const rangeT &keylist, const Value &value) |
| template<typename rangeT , typename Value > | |
| std::enable_if_t<!meta::is_void_v< Value >, void > | broadcast (const rangeT &keylist, Value &&value) |
| template<typename rangeT , typename Value = valueT> | |
| std::enable_if_t< meta::is_void_v< Value >, void > | broadcast (const rangeT &keylist) |
| template<typename rangeT , typename Value > | |
| void | prepare_send (const rangeT &keylist, Value &&value) |
| template<typename Value > | |
| void | prepare_send (Value &&value) |
Public Member Functions inherited from ttg::InTerminalBase< keyT > | |
| template<typename Key = keyT> | |
| std::enable_if_t<!meta::is_void_v< Key >, void > | set_size (const Key &key, std::size_t size) |
| template<typename Key = keyT> | |
| std::enable_if_t< meta::is_void_v< Key >, void > | set_size (std::size_t size) |
| template<typename Key = keyT> | |
| std::enable_if_t<!meta::is_void_v< Key >, void > | finalize (const Key &key) |
| template<typename Key = keyT> | |
| std::enable_if_t< meta::is_void_v< Key >, void > | finalize () |
Public Member Functions inherited from ttg::TerminalBase | |
| TTBase * | get_tt () const |
| Return ptr to containing tt. | |
| size_t | get_index () const |
| Returns index of terminal. | |
| const std::string & | get_name () const |
| Returns name of terminal. | |
| const std::string & | get_key_type_str () const |
| Returns string representation of key type. | |
| const std::string & | get_value_type_str () const |
| Returns string representation of value type. | |
| Type | get_type () const |
| Returns the terminal type. | |
| const std::vector< TerminalBase * > & | get_connections () const |
| Get connections to successors. | |
| const std::vector< TerminalBase * > & | get_predecessors () const |
| void | connect_pull_nopred (TerminalBase *p) |
| bool | is_connected () const |
| Returns true if this terminal (input or output) is connected. | |
| virtual | ~TerminalBase ()=default |
Public Attributes | |
| ttg::detail::ContainerWrapper< keyT, valueT > | container |
Public Attributes inherited from ttg::TerminalBase | |
| bool | is_pull_terminal = false |
Static Public Attributes | |
| static constexpr bool | is_an_input_terminal = true |
Static Public Attributes inherited from ttg::InTerminalBase< keyT > | |
| static constexpr bool | is_an_input_terminal = true |
Static Public Attributes inherited from ttg::TerminalBase | |
| static constexpr bool | is_a_terminal = true |
Additional Inherited Members | |
Protected Member Functions inherited from ttg::InTerminalBase< keyT > | |
| InTerminalBase (TerminalBase::Type t) | |
| void | set_callback (const setsize_callback_type &setsize_callback=setsize_callback_type{}, const finalize_callback_type &finalize_callback=finalize_callback_type{}) |
Protected Member Functions inherited from ttg::TerminalBase | |
| TerminalBase (Type type) | |
| void | set (TTBase *tt, size_t index, const std::string &name, const std::string &key_type_str, const std::string &value_type_str, Type type) |
| void | connect_base (TerminalBase *successor) |
| void | connect_pull (TerminalBase *predecessor) |
Protected Attributes inherited from ttg::InTerminalBase< keyT > | |
| setsize_callback_type | setsize_callback |
| finalize_callback_type | finalize_callback |
An input terminal for receiving messages annotated by task IDs of type KeyT and values of type valueT
| <keyT> | a task ID type (can be void) |
| <valueT> | a data type (can be void); a const valueT indicates that the incoming data is passed by const reference |
Definition at line 143 of file terminal.h.
| using ttg::In< keyT, valueT >::base_type = InTerminalBase<keyT> |
Definition at line 145 of file terminal.h.
| using ttg::In< keyT, valueT >::broadcast_callback_type = meta::detail::broadcast_callback_t<keyT, std::decay_t<valueT> > |
Definition at line 155 of file terminal.h.
| using ttg::In< keyT, valueT >::edge_type = Edge<keyT, valueT> |
Definition at line 152 of file terminal.h.
| using ttg::In< keyT, valueT >::finalize_callback_type = typename base_type::finalize_callback_type |
Definition at line 157 of file terminal.h.
| typedef keyT ttg::In< keyT, valueT >::key_type |
Definition at line 147 of file terminal.h.
| using ttg::In< keyT, valueT >::move_callback_type = meta::detail::move_callback_t<keyT, std::decay_t<valueT> > |
Definition at line 154 of file terminal.h.
| using ttg::In< keyT, valueT >::prepare_send_callback_type = meta::detail::prepare_send_callback_t<keyT, std::decay_t<valueT> > |
Definition at line 158 of file terminal.h.
| using ttg::In< keyT, valueT >::send_callback_type = meta::detail::send_callback_t<keyT, std::decay_t<valueT> > |
Definition at line 153 of file terminal.h.
| using ttg::In< keyT, valueT >::setsize_callback_type = typename base_type::setsize_callback_type |
Definition at line 156 of file terminal.h.
| typedef valueT ttg::In< keyT, valueT >::value_type |
Definition at line 146 of file terminal.h.
|
inline |
Default constructor of an Input Terminal.
Definition at line 180 of file terminal.h.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 334 of file terminal.h.
|
inline |
Definition at line 246 of file terminal.h.
|
inline |
Definition at line 206 of file terminal.h.
|
inline |
Definition at line 221 of file terminal.h.
|
inline |
Definition at line 230 of file terminal.h.
|
inline |
Define the callbacks used by the backend task system to implement data movement when a data is set in this Input Terminal
| [in] | send_callback | when an object must be copied inside this terminal |
| [in] | move_callback | when a rvalue reference is std::move onto this terminal |
| [in] | bcast_callback | when this terminal receives a list of task identifiers to broadcast a data to |
| [in] | finalize_callback | if the terminal is a reduce terminal, denotes that no other local thread will continue adding data onto this terminal |
| [in] | setsize_callback | if the terminal is a reduce terminal, announces how many items will be set unto this terminal for reduction |
| [in] | prepare_send_callback | for resumable/device tasks this is called before actual send |
Definition at line 192 of file terminal.h.
| ttg::detail::ContainerWrapper<keyT, valueT> ttg::In< keyT, valueT >::container |
Definition at line 160 of file terminal.h.
|
staticconstexpr |
Definition at line 159 of file terminal.h.
1.9.8