Inheritance diagram for ttg::TTBase:
ttg_parsec::TT< int, std::tuple< Out< int, Value >, Out< int, Value >, Out< int, Value >, Out< OutKey, Value > >, BinaryTreeReduce< Value, BinaryOp, OutKey >, ttg::typelist< Value, Value, Value > > ttg_parsec::TT< int, std::tuple< Out< int, Value >, Out< int, Value >, Out< int, Value > >, BinaryTreeBroadcast< Value, int >, ttg::typelist< Value > > ttg::SinkTT< keyT, input_valueT > ttg::TTG< input_terminalsT, output_terminalsT > ttg_madness::TT< keyT, output_terminalsT, derivedT, input_valueTs > ttg_parsec::TT< keyT, output_terminalsT, derivedT, input_valueTs > ttg::BinaryTreeReduce< Value, BinaryOp, OutKey > ttg::BinaryTreeBroadcast< Value, OutKey >

Documentation

A base class for all template tasks.

Definition at line 30 of file tt.h.

Public Member Functions

virtual ~TTBase ()=default
 
virtual void invoke ()
 
bool set_trace_instance (bool value)
 
bool tracing () const
 
template<typename T , typename... Ts>
void trace (const T &t, const Ts &...ts)
 Like ttg::trace(), but only produces tracing output if this->tracing()==true More...
 
bool set_lazy_pull_instance (bool value)
 
bool is_lazy_pull ()
 
std::optional< std::reference_wrapper< const TTBase > > ttg () const
 
const TTBasettg_ptr () const
 
bool is_ttg () const
 
void set_name (const std::string &name)
 Sets the name of this operation. More...
 
const std::string & get_name () const
 Gets the name of this operation. More...
 
std::string get_class_name () const
 Gets the demangled class name (uses RTTI) More...
 
const std::vector< TerminalBase * > & get_inputs () const
 Returns the vector of input terminals. More...
 
const std::vector< TerminalBase * > & get_outputs () const
 Returns the vector of output terminals. More...
 
virtual ttg::World get_world () const =0
 
ttg::TerminalBasein (size_t i)
 Returns a pointer to the i'th input terminal. More...
 
ttg::TerminalBaseout (size_t i)
 Returns a pointer to the i'th output terminal. More...
 
template<std::size_t i>
ttg::TerminalBasein ()
 Returns a pointer to the i'th input terminal ... to make API consistent with TT. More...
 
template<std::size_t i>
ttg::TerminalBaseout ()
 Returns a pointer to the i'th output terminal ... to make API consistent with TT. More...
 
auto get_instance_id () const
 
virtual void fence ()=0
 
virtual void release ()
 
virtual void make_executable ()=0
 Marks this executable. More...
 
bool is_executable () const
 

Static Public Member Functions

static bool set_trace_all (bool value)
 
static bool set_lazy_pull (bool value)
 
static const std::vector< TerminalBase * > * get_outputs_tls_ptr ()
 Returns this thread's pointer to the vector of output terminals. More...
 

Protected Member Functions

void set_input (size_t i, TerminalBase *t)
 
void set_output (size_t i, TerminalBase *t)
 
template<bool out, typename terminalT , std::size_t i, typename setfuncT >
void register_terminal (terminalT &term, const std::string &name, const setfuncT setfunc)
 
template<bool out, std::size_t... IS, typename terminalsT , typename namesT , typename setfuncT >
void register_terminals (std::index_sequence< IS... >, terminalsT &terms, const namesT &names, const setfuncT setfunc)
 
template<typename terminalsT , typename namesT >
void register_input_terminals (terminalsT &terms, const namesT &names)
 
template<typename terminalsT , typename namesT >
void register_output_terminals (terminalsT &terms, const namesT &names)
 
template<std::size_t... IS, typename terminalsT , typename setfuncT >
void set_terminals (std::index_sequence< IS... >, terminalsT &terms, const setfuncT setfunc)
 
template<typename terminalsT , typename setfuncT >
void set_terminals (const terminalsT &terms, const setfuncT setfunc)
 
 TTBase (TTBase &&other)
 
TTBaseoperator= (TTBase &&other)
 
 TTBase (const std::string &name, size_t numins, size_t numouts)
 
void set_outputs_tls_ptr ()
 
void set_outputs_tls_ptr (const std::vector< TerminalBase * > *ptr)
 

Static Protected Member Functions

static const std::vector< TerminalBase * > *& outputs_tls_ptr_accessor ()
 

Friends

template<typename input_terminalsT , typename output_terminalsT >
class TTG
 

Constructor & Destructor Documentation

◆ TTBase() [1/2]

ttg::TTBase::TTBase ( TTBase &&  other)
inlineprotected

Definition at line 115 of file tt.h.

◆ TTBase() [2/2]

ttg::TTBase::TTBase ( const std::string &  name,
size_t  numins,
size_t  numouts 
)
inlineprotected

Definition at line 133 of file tt.h.

◆ ~TTBase()

virtual ttg::TTBase::~TTBase ( )
virtualdefault

Member Function Documentation

◆ fence()

virtual void ttg::TTBase::fence ( )
pure virtual

Waits for the entire TTG that contains this object to be completed (collective); if not contained by a TTG this is a no-op

Implemented in ttg::SinkTT< keyT, input_valueT >, ttg::TTG< input_terminalsT, output_terminalsT >, and ttg_madness::TT< keyT, output_terminalsT, derivedT, input_valueTs >.

◆ get_class_name()

std::string ttg::TTBase::get_class_name ( ) const
inline

Gets the demangled class name (uses RTTI)

Definition at line 220 of file tt.h.

◆ get_inputs()

const std::vector<TerminalBase *>& ttg::TTBase::get_inputs ( ) const
inline

Returns the vector of input terminals.

Definition at line 223 of file tt.h.

◆ get_instance_id()

auto ttg::TTBase::get_instance_id ( ) const
inline

Definition at line 258 of file tt.h.

◆ get_name()

const std::string& ttg::TTBase::get_name ( ) const
inline

Gets the name of this operation.

Definition at line 217 of file tt.h.

◆ get_outputs()

const std::vector<TerminalBase *>& ttg::TTBase::get_outputs ( ) const
inline

Returns the vector of output terminals.

Definition at line 226 of file tt.h.

◆ get_outputs_tls_ptr()

static const std::vector<TerminalBase *>* ttg::TTBase::get_outputs_tls_ptr ( )
inlinestatic

Returns this thread's pointer to the vector of output terminals.

Definition at line 229 of file tt.h.

◆ get_world()

◆ in() [1/2]

template<std::size_t i>
ttg::TerminalBase* ttg::TTBase::in ( )
inline

Returns a pointer to the i'th input terminal ... to make API consistent with TT.

Definition at line 248 of file tt.h.

◆ in() [2/2]

ttg::TerminalBase* ttg::TTBase::in ( size_t  i)
inline

Returns a pointer to the i'th input terminal.

Definition at line 235 of file tt.h.

◆ invoke()

◆ is_executable()

bool ttg::TTBase::is_executable ( ) const
inline

Queries if this ready to execute

Returns
true is this object is executable

Definition at line 271 of file tt.h.

◆ is_lazy_pull()

bool ttg::TTBase::is_lazy_pull ( )
inline

Definition at line 199 of file tt.h.

◆ is_ttg()

bool ttg::TTBase::is_ttg ( ) const
inline

Definition at line 209 of file tt.h.

◆ make_executable()

◆ operator=()

TTBase& ttg::TTBase::operator= ( TTBase &&  other)
inlineprotected

Definition at line 123 of file tt.h.

◆ out() [1/2]

template<std::size_t i>
ttg::TerminalBase* ttg::TTBase::out ( )
inline

Returns a pointer to the i'th output terminal ... to make API consistent with TT.

Definition at line 254 of file tt.h.

◆ out() [2/2]

ttg::TerminalBase* ttg::TTBase::out ( size_t  i)
inline

Returns a pointer to the i'th output terminal.

Definition at line 241 of file tt.h.

◆ outputs_tls_ptr_accessor()

static const std::vector<TerminalBase *>*& ttg::TTBase::outputs_tls_ptr_accessor ( )
inlinestaticprotected

Definition at line 136 of file tt.h.

◆ register_input_terminals()

template<typename terminalsT , typename namesT >
void ttg::TTBase::register_input_terminals ( terminalsT &  terms,
const namesT &  names 
)
inlineprotected

Definition at line 84 of file tt.h.

◆ register_output_terminals()

template<typename terminalsT , typename namesT >
void ttg::TTBase::register_output_terminals ( terminalsT &  terms,
const namesT &  names 
)
inlineprotected

Definition at line 91 of file tt.h.

◆ register_terminal()

template<bool out, typename terminalT , std::size_t i, typename setfuncT >
void ttg::TTBase::register_terminal ( terminalT &  term,
const std::string &  name,
const setfuncT  setfunc 
)
inlineprotected

Definition at line 64 of file tt.h.

◆ register_terminals()

template<bool out, std::size_t... IS, typename terminalsT , typename namesT , typename setfuncT >
void ttg::TTBase::register_terminals ( std::index_sequence< IS... >  ,
terminalsT &  terms,
const namesT &  names,
const setfuncT  setfunc 
)
inlineprotected

Definition at line 74 of file tt.h.

◆ release()

◆ set_input()

void ttg::TTBase::set_input ( size_t  i,
TerminalBase t 
)
inlineprotected

Definition at line 53 of file tt.h.

◆ set_lazy_pull()

static bool ttg::TTBase::set_lazy_pull ( bool  value)
inlinestatic

Definition at line 164 of file tt.h.

◆ set_lazy_pull_instance()

bool ttg::TTBase::set_lazy_pull_instance ( bool  value)
inline

Definition at line 194 of file tt.h.

◆ set_name()

void ttg::TTBase::set_name ( const std::string &  name)
inline

Sets the name of this operation.

Definition at line 214 of file tt.h.

◆ set_output()

void ttg::TTBase::set_output ( size_t  i,
TerminalBase t 
)
inlineprotected

Definition at line 58 of file tt.h.

◆ set_outputs_tls_ptr() [1/2]

void ttg::TTBase::set_outputs_tls_ptr ( )
inlineprotected

Definition at line 140 of file tt.h.

◆ set_outputs_tls_ptr() [2/2]

void ttg::TTBase::set_outputs_tls_ptr ( const std::vector< TerminalBase * > *  ptr)
inlineprotected

Definition at line 141 of file tt.h.

◆ set_terminals() [1/2]

template<typename terminalsT , typename setfuncT >
void ttg::TTBase::set_terminals ( const terminalsT &  terms,
const setfuncT  setfunc 
)
inlineprotected

Definition at line 105 of file tt.h.

◆ set_terminals() [2/2]

template<std::size_t... IS, typename terminalsT , typename setfuncT >
void ttg::TTBase::set_terminals ( std::index_sequence< IS... >  ,
terminalsT &  terms,
const setfuncT  setfunc 
)
inlineprotected

Definition at line 98 of file tt.h.

◆ set_trace_all()

static bool ttg::TTBase::set_trace_all ( bool  value)
inlinestatic

Sets trace for all operations to value and returns previous setting. This has no effect unless trace_enabled()==true

Definition at line 156 of file tt.h.

◆ set_trace_instance()

bool ttg::TTBase::set_trace_instance ( bool  value)
inline

Sets trace for just this instance to value and returns previous setting This has no effect unless trace_enabled()==true

Definition at line 171 of file tt.h.

◆ trace()

template<typename T , typename... Ts>
void ttg::TTBase::trace ( const T &  t,
const Ts &...  ts 
)
inline

Like ttg::trace(), but only produces tracing output if this->tracing()==true

Definition at line 186 of file tt.h.

◆ tracing()

bool ttg::TTBase::tracing ( ) const
inline
Returns
false if trace_enabled()==false, else true if tracing set for either this instance or all instances

Definition at line 177 of file tt.h.

◆ ttg()

std::optional<std::reference_wrapper<const TTBase> > ttg::TTBase::ttg ( ) const
inline

Definition at line 201 of file tt.h.

◆ ttg_ptr()

const TTBase* ttg::TTBase::ttg_ptr ( ) const
inline

Definition at line 205 of file tt.h.

Friends And Related Function Documentation

◆ TTG

template<typename input_terminalsT , typename output_terminalsT >
friend class TTG
friend

Definition at line 40 of file tt.h.


The documentation for this class was generated from the following file: