geopm
3.1.1.dev214+gba4f9f6d
GEOPM - Global Extensible Open Power Manager
|
Filter that can be used to synthesize epoch events from a sequence of region entry events. The filter suppresses received epoch events and passes through all other events. More...
#include <ProxyEpochRecordFilter.hpp>
Public Member Functions | |
ProxyEpochRecordFilter (uint64_t region_hash, int calls_per_epoch, int startup_count) | |
Constructor for a process specific proxy-region EpochIOGroup record filter. More... | |
ProxyEpochRecordFilter (const std::string &filter_name) | |
virtual | ~ProxyEpochRecordFilter ()=default |
Default destructor. More... | |
std::vector< record_s > | filter (const record_s &record) |
If input record matches the periodic entry into the proxy-region matching the construction arguments, then the output will be a vector of length one containing the inferred M_EVENT_EPOCH_COUNT event. In all other cases the method returns an empty vector. More... | |
Public Member Functions inherited from geopm::RecordFilter | |
RecordFilter ()=default | |
Default constructor for pure virtual interface. More... | |
virtual | ~RecordFilter ()=default |
Default destructor for pure virtual interface. More... | |
Static Public Member Functions | |
static void | parse_name (const std::string &name, uint64_t ®ion_hash, int &calls_per_epoch, int &startup_count) |
Static function that will parse the filter string for the proxy_epoch into the constructor arguments for a ProxyEpochRecordFilter. Failure to parse will result in a thrown Exception with GEOPM_ERROR_INVALID type. More... | |
Static Public Member Functions inherited from geopm::RecordFilter | |
static std::unique_ptr< RecordFilter > | make_unique (const std::string &name) |
Filter that can be used to synthesize epoch events from a sequence of region entry events. The filter suppresses received epoch events and passes through all other events.
This filter is used to insert synthetic epoch events into the stream received by an application process. This provides users of the ApplicationSampler with epoch events even if the application does not provide them directly through calls to geopm_prof_epoch(). When this filter is selected, any epoch events that arrive though the application calls into geopm_prof_epoch() are removed from the record stream. The output of this filter is a pass through of all non-epoch events and may include synthesized epoch events. The epoch events are synthesized from region entry of a specified region that may be detected through runtimes like MPI function calls or OpenMP parallel regions. This proxy-region is specified at filter construction time by the region hash. Typically, this region hash value is determined by inspection of a report from a previous run. There are two other constructor parameters that enable support for multiple proxy-region entries per outer loop, and for application calls into the proxy-region prior to the beginning of the outer loop. The filter assumes that the provided records have been collected from a single process.
geopm::ProxyEpochRecordFilter::ProxyEpochRecordFilter | ( | uint64_t | region_hash, |
int | calls_per_epoch, | ||
int | startup_count | ||
) |
Constructor for a process specific proxy-region EpochIOGroup record filter.
[in] | region_hash | The hash for the region that will be used as a proxy for the epoch events. |
[in] | calls_per_epoch | Number of calls to the proxy-region that are expected in each outer loop of the application per process. |
[in] | startup_count | Number of calls to the proxy- region that are to be ignored at application startup. These calls are expected prior to entering the outer loop of the application. |
geopm::ProxyEpochRecordFilter::ProxyEpochRecordFilter | ( | const std::string & | filter_name | ) |
|
virtualdefault |
Default destructor.
If input record matches the periodic entry into the proxy-region matching the construction arguments, then the output will be a vector of length one containing the inferred M_EVENT_EPOCH_COUNT event. In all other cases the method returns an empty vector.
Implements geopm::RecordFilter.
|
static |
Static function that will parse the filter string for the proxy_epoch into the constructor arguments for a ProxyEpochRecordFilter. Failure to parse will result in a thrown Exception with GEOPM_ERROR_INVALID type.
[in] | name | The filter name which is of the form "proxy_epoch,<HASH>[,<CALLS>[,<STARTUP>]]" The region hash is always parsed (i.e. required). If the calls per epoch is provided or if both the call per epoch and startup count are provided they are also parsed. The default value for calls_per_epoch is 1 and for startup_count is 0. |
[out] | region_hash | The hash of the region that will serve as the proxy for the epoch. |
[out] | calls_per_epoch | Number of entries into the proxy-region expected in each outer loop of the application. |
[out] | startup_count | Number of entries into the proxy-region expected prior to the beginning of the outer loop of the application. |