|
MADNESS 0.10.1
|
base class More...
#include <macrotaskq.h>

Public Types | |
| enum | Status { Running , Waiting , Complete , Unknown } |
| typedef std::vector< std::shared_ptr< MacroTaskBase > > | taskqT |
Public Member Functions | |
| MacroTaskBase () | |
| virtual | ~MacroTaskBase () |
| virtual void | cleanup ()=0 |
| virtual void | finalize_stage1 (World &, World *, Cloud &) |
| virtual void | finalize_stage2 (World &, World *, Cloud &) |
| long | get_owner_slot () const |
| double | get_priority () const |
| bool | is_complete () const |
| bool | is_owned_by (const long slot) const |
| an unowned task may be run by any subworld, an owned one only by its own | |
| bool | is_running () const |
| bool | is_waiting () const |
| virtual void | print_me (std::string s="") const |
| virtual void | print_me_as_table (std::string s="") const |
| std::string | print_priority_and_status_to_string () const |
| virtual void | run (World &world, Cloud &cloud, taskqT &taskq, const long element, const bool debug, const MacroTaskInfo policy)=0 |
| void | set_complete () |
| void | set_owner_slot (const long owner) |
| void | set_priority (const double p) |
| void | set_running () |
| void | set_waiting () |
| virtual bool | wants_node_local_reduction () const |
| Finalize, for tasks that accumulate their own output. | |
Public Attributes | |
| long | owner_slot =-1 |
| the subworld that should run this task; -1 means any | |
| double | priority =1.0 |
| enum madness::MacroTaskBase::Status | stat =Unknown |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const MacroTaskBase::Status s) |
base class
| typedef std::vector<std::shared_ptr<MacroTaskBase> > madness::MacroTaskBase::taskqT |
|
inline |
|
inlinevirtual |
Reimplemented in madness::MacroTask< taskT >::MacroTaskInternal.
Reimplemented in madness::MacroTask< taskT >::MacroTaskInternal.
|
inline |
References owner_slot.
Referenced by madness::MacroTask< taskT >::MacroTaskInternal::find_next_owned_task().
|
inline |
References priority.
Referenced by print_priority_and_status_to_string().
an unowned task may be run by any subworld, an owned one only by its own
References madness::nonlinear_vector_solver(), and owner_slot.
Referenced by madness::MacroTask< taskT >::MacroTaskInternal::find_next_owned_task().
Reimplemented in madness::MacroTask< taskT >::MacroTaskInternal.
References madness::nonlinear_vector_solver(), and priority.
Reimplemented in madness::MacroTask< taskT >::MacroTaskInternal.
References madness::print().
|
inline |
References get_priority(), madness::nonlinear_vector_solver(), and stat.
Referenced by madness::MacroTask< taskT >::MacroTaskInternal::print_me_as_table().
|
pure virtual |
Implemented in madness::MacroTask< taskT >::MacroTaskInternal.
References owner_slot.
Referenced by madness::MacroTask< taskT >::MacroTaskInternal::MacroTaskInternal().
Finalize, for tasks that accumulate their own output.
run_all holds only base pointers, so these have to be virtual. Stage 1 reduces the per-subworld buffers within a node, stage 2 reduces across nodes into the universe result; a nodeworld of nullptr means one node, so stage 1 has nothing to do.
Reimplemented in madness::MacroTask< taskT >::MacroTaskInternal.
|
friend |
| long madness::MacroTaskBase::owner_slot =-1 |
the subworld that should run this task; -1 means any
Referenced by madness::MacroTask< taskT >::MacroTaskInternal::MacroTaskInternal(), madness::MacroTask< taskT >::MacroTaskInternal::find_next_owned_task(), get_owner_slot(), is_owned_by(), and set_owner_slot().
| double madness::MacroTaskBase::priority =1.0 |
| enum madness::MacroTaskBase::Status madness::MacroTaskBase::stat =Unknown |
Referenced by is_complete(), is_running(), is_waiting(), print_priority_and_status_to_string(), set_complete(), set_running(), and set_waiting().