CnC
 All Classes Namespaces Functions Variables Typedefs Enumerator Friends
Public Member Functions
cancel_tuner< Tag, check_deps, Hasher, Equality > Class Template Reference

Step tuner with convenient cancelation capabilities. More...

List of all members.

Public Member Functions

void cancel (const Tag &t, bool from_msg=false)
 cancel given step (identified by tag)
void cancel_all (bool from_msg=false)
 cancel all steps
template<typename Arg >
int was_canceled (const Tag &tag, Arg &) const
 implements/overwrites step_tuner::was_canceled(...)

Detailed Description

template<typename Tag, bool check_deps = true, typename Hasher = cnc_hash< Tag >, typename Equality = cnc_equal< Tag >>
class CnC::cancel_tuner< Tag, check_deps, Hasher, Equality >

Step tuner with convenient cancelation capabilities.

Allows cancelation of individual step-instances by their tags as well as canceling all instances at once. All cancelation requests are "active" until unsafe_reset() is called (or the tuner is destructed).

To use it, you need a cancel_tuner object in your context which you pass to the constructor of the respective step_collection.

It works on distributed memory but might perform poorly if used frequently.

Parameters:
Tagtag-type
check_depsif false, avoid some mechanics to handle unavailable items
Hasherhash-functor for Tag, defaults to tbb::tbb_hash< Tag >
Equalityequality operator for Tag, defaults to std::equal_to< Tag >
Note:
It is assumed that cancelation per instance happens relatively rarely. Hence no automatic garbage collection of the tags is provided. If you cancel individual step-instances frequently, it is recommended to prune the internal data structure from time to time in a safe state through unsafe_reset().
See also:
also CNCROOT/samples/floyd_warshall

Definition at line 323 of file default_tuner.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Enumerator Friends