|
HLIBpro 3.2
|
describes a processor set of continuously numbered processors
#include <TProcSet.hh>
Public Member Functions | |
| TProcSet (const uint ps_size=0) noexcept | |
| constructs set of size ps_size | |
| TProcSet (const uint ps_first, const uint ps_last) noexcept | |
| constructs set from ps_first to ps_last | |
| TProcSet (const TProcSet &ps) noexcept | |
| copy constructor | |
| uint | first () const noexcept |
| return ID of first processor in set | |
| uint | last () const noexcept |
| return ID of last processor in set | |
| TProcSet | subset (const uint i, const uint n=2) const noexcept |
| return i'th subset in an n-partition of the local set | |
| void | split (const uint n, std::vector< TProcSet > &psets) const |
| split processor set in n subsets (of approx. equal size) | |
| TProcSet | join (const TProcSet &ps) const noexcept |
| return union with given procsessor set | |
| bool | is_in (const uint p) const noexcept |
| return true if given proc is in set | |
| uint | size () const noexcept |
| return size of set | |
| bool | empty () const noexcept |
| return true if processor set is empty | |
| uint | master () const noexcept |
| return id of master processor | |
| TProcSet & | operator= (const TProcSet &ps) noexcept |
| copy operator | |
| bool | operator== (const TProcSet &ps) const noexcept |
| equality operators | |
| bool | operator!= (const TProcSet &ps) const noexcept |
| inequality operators | |
| size_t | byte_size () const noexcept |
| return size in bytes used by this object | |
| std::string | to_string () const |
| return string representation | |
| void | read (TByteStream &s) |
| read data from stream | |
| void | write (TByteStream &s) const |
| write data to stream | |
| size_t | bs_size () const |
| returns size of object in bytestream | |
Construct a processor set defined by minimum of first processor and maximum of last processor in both sets
Split local processor set into n subsets of approximately the same size and return the partition in psets
| n | number of subsets to generate |
| psets | array to store the subsets |