#include "timemory/components/craypat/components.hpp"
Definition at line 125 of file components.hpp.
◆ base_type
◆ storage_type
◆ strvector_t
◆ this_type
◆ value_type
◆ configure()
static void tim::component::craypat_counters::configure |
( |
| ) |
|
|
inlinestatic |
Definition at line 141 of file components.hpp.
143 std::set<int> _empty;
145 for(
auto& citr : get_persistent_data().m_categories)
147 int _category = std::get<0>(citr);
149 const char** _names =
nullptr;
150 unsigned long* _values =
nullptr;
151 int* _nevents =
nullptr;
153 backend::craypat::counters(_category, _names, _values, _nevents);
154 if(_names && _values && _nevents)
156 std::get<1>(citr) = *_nevents;
157 for(
int i = 0; i < *_nevents; ++i)
159 std::get<2>(citr).push_back(_names[i]);
160 get_persistent_data().m_labels.push_back(_names[i]);
170 get_persistent_data().m_events = get_persistent_data().m_labels.size();
173 for(
auto ritr = _empty.rbegin(); ritr != _empty.rend(); ++ritr)
175 auto itr = get_persistent_data().m_categories.begin();
176 std::advance(itr, *ritr);
177 get_persistent_data().m_categories.erase(itr);
Referenced by global_init().
◆ description()
static std::string tim::component::craypat_counters::description |
( |
| ) |
|
|
inlinestatic |
Definition at line 135 of file components.hpp.
137 return "Names and value of any counter events that have been set to count on the "
◆ description_array()
static strvector_t tim::component::craypat_counters::description_array |
( |
| ) |
|
|
inlinestatic |
Definition at line 212 of file components.hpp.
214 return strvector_t(get_persistent_data().m_events,
"");
std::vector< std::string > strvector_t
◆ display_unit_array()
static strvector_t tim::component::craypat_counters::display_unit_array |
( |
| ) |
|
|
inlinestatic |
◆ get()
value_type tim::component::craypat_counters::get |
( |
| ) |
const |
|
inline |
◆ get_display()
value_type tim::component::craypat_counters::get_display |
( |
| ) |
const |
|
inline |
◆ get_opaque()
template<typename... Args>
static opaque tim::component::empty_base::get_opaque |
( |
Args && |
... | ) |
|
|
inlinestaticinherited |
◆ global_init()
static void tim::component::craypat_counters::global_init |
( |
| ) |
|
|
inlinestatic |
◆ label()
static std::string tim::component::craypat_counters::label |
( |
| ) |
|
|
inlinestatic |
◆ label_array()
static strvector_t tim::component::craypat_counters::label_array |
( |
| ) |
|
|
inlinestatic |
Definition at line 210 of file components.hpp.
210{
return get_persistent_data().m_labels; }
◆ record()
static value_type tim::component::craypat_counters::record |
( |
| ) |
|
|
inlinestatic |
Definition at line 183 of file components.hpp.
186 for(
const auto& citr : get_persistent_data().m_categories)
188 int _category = std::get<0>(citr);
190 const char** _names =
nullptr;
191 unsigned long* _values =
nullptr;
192 int* _nevents =
nullptr;
194 backend::craypat::counters(_category, _names, _values, _nevents);
195 if(_names && _values && _nevents)
198 auto _off = _data.size();
200 _data.resize(_off + std::get<1>(citr), 0);
202 int _n =
std::min(std::get<1>(citr), *_nevents);
203 for(
int i = 0; i < _n; ++i)
204 _data[_off + i] = _values[i];
::tim::statistics< Tp > min(::tim::statistics< Tp > lhs, const Tp &rhs)
std::vector< unsigned long > value_type
References std::min().
Referenced by start(), and stop().
◆ start()
void tim::component::craypat_counters::start |
( |
| ) |
|
|
inline |
◆ stop()
void tim::component::craypat_counters::stop |
( |
| ) |
|
|
inline |
◆ unit_array()
static std::vector< unsigned long > tim::component::craypat_counters::unit_array |
( |
| ) |
|
|
inlinestatic |
Definition at line 217 of file components.hpp.
219 return std::vector<unsigned long>(get_persistent_data().m_events, 1);
The documentation for this struct was generated from the following file: