|
Sacado Package Browser (Single Doxygen Collection) Version of the Day
|
Class storing flop counts and summary flop counts. More...
#include <Sacado_ScalarFlopCounter.hpp>
Public Types | |
| enum | { NUM_OPS = 34 } |
| Number of total operation supported up till now. More... | |
| enum | EFlopType { ASSIGN , PLUS , PLUS_ASSIGN , UNARY_PLUS , MINUS , MINUS_ASSIGN , UNARY_MINUS , MULTIPLY , MULTIPLY_ASSIGN , DIVIDE , DIVIDE_ASSIGN , GREATER_THAN , GREATER_THAN_EQUAL , LESS_THAN , LESS_THAN_EQUAL , EQUAL , EXP , LOG , LOG10 , SQRT , COS , SIN , TAN , ACOS , ASIN , ATAN , ATAN2 , COSH , SINH , TANH , ABS , POW , MAX , MIN } |
| Enum for operations. More... | |
| enum | { NUM_SUMMARY_OPS = 6 } |
| Number of summary operation categories. More... | |
| enum | ESummaryFlopType { SUMMARY_ASSIGN , SUMMARY_PLUS_MINUS , SUMMARY_MULTIPLY , SUMMARY_DIVIDE , SUMMARY_COMPARISON , SUMMARY_NONLINEAR } |
| Enum of summary operation categories. More... | |
Public Member Functions | |
| FlopCounts () | |
| Default constructor. | |
| void | reset () |
| Reset flop counters before starting a block of computations. */. | |
| void | finalize () |
| void | increment (EFlopType ft) |
| Increment an individual flop counter. | |
Public Attributes | |
| double | flopCounts [NUM_OPS] |
| Individual flop counts. | |
| double | summaryFlopCounts [NUM_SUMMARY_OPS] |
| Summary category flop counts. | |
| double | totalFlopCount |
| Total flop count. | |
Static Public Attributes | |
| static const char * | flopCountsNames [NUM_OPS] |
| Names of individual flops. | |
| static const char * | summaryFlopCountsNames [NUM_SUMMARY_OPS] |
| Names for summary operation categories. | |
| static unsigned int | flopGranularity = 100000000 |
| The number of flops to accumulate as an integer before converting to a double. | |
Private Member Functions | |
| ESummaryFlopType | getSummaryType (EFlopType ft) |
| Get summary op enum from op enum. | |
Private Attributes | |
| unsigned int | partialFlopCounts [NUM_OPS] |
| Partial sum of individual flop counts. | |
| unsigned int | partialSummaryFlopCounts [NUM_SUMMARY_OPS] |
| Partial sum of summary category flop counts. | |
Class storing flop counts and summary flop counts.
Definition at line 46 of file Sacado_ScalarFlopCounter.hpp.
| anonymous enum |
Number of total operation supported up till now.
| Enumerator | |
|---|---|
| NUM_OPS | |
Definition at line 54 of file Sacado_ScalarFlopCounter.hpp.
Enum for operations.
Definition at line 57 of file Sacado_ScalarFlopCounter.hpp.
| anonymous enum |
Number of summary operation categories.
| Enumerator | |
|---|---|
| NUM_SUMMARY_OPS | |
Definition at line 98 of file Sacado_ScalarFlopCounter.hpp.
Enum of summary operation categories.
| Enumerator | |
|---|---|
| SUMMARY_ASSIGN | |
| SUMMARY_PLUS_MINUS | |
| SUMMARY_MULTIPLY | |
| SUMMARY_DIVIDE | |
| SUMMARY_COMPARISON | |
| SUMMARY_NONLINEAR | |
Definition at line 101 of file Sacado_ScalarFlopCounter.hpp.
| Sacado::FlopCounterPack::FlopCounts::FlopCounts | ( | ) |
Default constructor.
Definition at line 93 of file Sacado_ScalarFlopCounter.cpp.
| void Sacado::FlopCounterPack::FlopCounts::reset | ( | ) |
Reset flop counters before starting a block of computations. */.
Definition at line 99 of file Sacado_ScalarFlopCounter.cpp.
| void Sacado::FlopCounterPack::FlopCounts::finalize | ( | ) |
Definition at line 110 of file Sacado_ScalarFlopCounter.cpp.
| void Sacado::FlopCounterPack::FlopCounts::increment | ( | EFlopType | ft | ) |
Increment an individual flop counter.
Definition at line 126 of file Sacado_ScalarFlopCounter.cpp.
|
private |
Get summary op enum from op enum.
Definition at line 143 of file Sacado_ScalarFlopCounter.cpp.
|
static |
Names of individual flops.
Definition at line 111 of file Sacado_ScalarFlopCounter.hpp.
|
static |
Names for summary operation categories.
Definition at line 114 of file Sacado_ScalarFlopCounter.hpp.
|
static |
The number of flops to accumulate as an integer before converting to a double.
The default value is 100 000 000 and must be less than UINT_MAX-1. Increasing this value may give somewhat better precision for the flop count when counting very large numbers of flops.
Definition at line 125 of file Sacado_ScalarFlopCounter.hpp.
| double Sacado::FlopCounterPack::FlopCounts::flopCounts[NUM_OPS] |
Individual flop counts.
Definition at line 128 of file Sacado_ScalarFlopCounter.hpp.
| double Sacado::FlopCounterPack::FlopCounts::summaryFlopCounts[NUM_SUMMARY_OPS] |
Summary category flop counts.
Definition at line 131 of file Sacado_ScalarFlopCounter.hpp.
| double Sacado::FlopCounterPack::FlopCounts::totalFlopCount |
Total flop count.
Definition at line 134 of file Sacado_ScalarFlopCounter.hpp.
|
private |
Partial sum of individual flop counts.
Definition at line 154 of file Sacado_ScalarFlopCounter.hpp.
|
private |
Partial sum of summary category flop counts.
Definition at line 157 of file Sacado_ScalarFlopCounter.hpp.