Counter that provides a fairly accurate timing mechanism for both windows and linux. This timer is used extensively in all the samples.
More...
#include <clsparseTimer.hpp>
|
virtual void | Start (size_t id)=0 |
| Start a timing sample.
|
|
virtual void | Stop (size_t id)=0 |
| Stop a timing sample.
|
|
virtual void | Clear ()=0 |
| Clear all internal data structures, deallocate all memory.
|
|
virtual void | Reset ()=0 |
| Clear all internal data structures, freeing all memory, then reallocate the same amount of memory requested with Reserve.
|
|
virtual void | Reserve (size_t nEvents, size_t nSamples)=0 |
| The implementation of the timing class may contains data structures that need to grow as more samples are collected. More...
|
|
virtual size_t | getUniqueID (const std::string &label, cl_uint groupID)=0 |
| Provide a mapping from a 'friendly' human readable text string to an index into internal data structures. More...
|
|
virtual void | setNormalize (bool norm)=0 |
| Request that the timer divides total samples collected by sample frequency, converting tick counts into seconds. More...
|
|
virtual void | Print (cl_ulong flopCount, std::string unit)=0 |
| Print the output of the timing information to the console. This includes information specific to the derived timer class. More...
|
|
virtual size_t | pruneOutliers (cl_double multiple)=0 |
| Using the stdDev of the entire population (of an id), eliminate those samples that fall outside some specified multiple of the stdDev. This assumes that the population form a Gaussian curve. More...
|
|
|
virtual | ~clsparseTimer () |
| Destructor for StatisticalTimer that cleans up the class.
|
|
Counter that provides a fairly accurate timing mechanism for both windows and linux. This timer is used extensively in all the samples.
virtual size_t clsparseTimer::getUniqueID |
( |
const std::string & |
label, |
|
|
cl_uint |
groupID |
|
) |
| |
|
pure virtual |
Provide a mapping from a 'friendly' human readable text string to an index into internal data structures.
- Parameters
-
[in] | label | Human readable string to textually identify the event |
[in] | groupID | A number paired with the string to differentiate identical strings |
virtual void clsparseTimer::Print |
( |
cl_ulong |
flopCount, |
|
|
std::string |
unit |
|
) |
| |
|
pure virtual |
Print the output of the timing information to the console. This includes information specific to the derived timer class.
- Parameters
-
[in] | flopCount | The number of flops in a calculation, to calculate the flop rate |
[in] | unit | String to represent the Unit to print |
virtual size_t clsparseTimer::pruneOutliers |
( |
cl_double |
multiple | ) |
|
|
pure virtual |
Using the stdDev of the entire population (of an id), eliminate those samples that fall outside some specified multiple of the stdDev. This assumes that the population form a Gaussian curve.
- Parameters
-
[in] | multiple | How many standard deviates to prune outliers, typically integer between 1..3 |
virtual void clsparseTimer::Reserve |
( |
size_t |
nEvents, |
|
|
size_t |
nSamples |
|
) |
| |
|
pure virtual |
The implementation of the timing class may contains data structures that need to grow as more samples are collected.
This function allows the client to specify to the timing class an estimate for the amount of memory required for the duration of the benchmark
- Parameters
-
[in] | nEvents | An event is an independent timing location of benchmark interest, such as two different functions |
[in] | nSamples | The number of samples that associated with an event, often a loop-count |
virtual void clsparseTimer::setNormalize |
( |
bool |
norm | ) |
|
|
pure virtual |
Request that the timer divides total samples collected by sample frequency, converting tick counts into seconds.
- Parameters
-
[in] | norm | True value will divide return result by frequency |
The documentation for this class was generated from the following file: