Botan 3.5.0
Crypto and TLS for C&
|
#include <timer.h>
Classes | |
class | Timer_Scope |
Public Member Functions | |
size_t | buf_size () const |
double | bytes_per_second () const |
uint64_t | cycles_consumed () const |
const std::string & | doing () const |
uint64_t | events () const |
double | events_per_second () const |
const std::string & | get_name () const |
double | milliseconds () const |
double | ms_per_event () const |
bool | operator< (const Timer &other) const |
Timer & | operator= (const Timer &other)=default |
template<typename F > | |
auto | run (F f) -> decltype(f()) |
template<typename F > | |
void | run_until_elapsed (std::chrono::milliseconds msec, F f) |
double | seconds () const |
double | seconds_per_event () const |
void | set_custom_msg (std::string_view s) |
void | start () |
void | stop () |
Timer (const Timer &other)=default | |
Timer (std::string_view name) | |
Timer (std::string_view name, size_t buf_size) | |
Timer (std::string_view name, std::string_view provider, std::string_view doing, uint64_t event_mult, size_t buf_size, double clock_cycle_ratio, uint64_t clock_speed) | |
std::string | to_string () const |
bool | under (std::chrono::milliseconds msec) const |
uint64_t | value () const |
Botan::Timer::Timer | ( | std::string_view | name, |
std::string_view | provider, | ||
std::string_view | doing, | ||
uint64_t | event_mult, | ||
size_t | buf_size, | ||
double | clock_cycle_ratio, | ||
uint64_t | clock_speed ) |
|
inline |
Definition at line 26 of file timer.h.
|
inline |
|
default |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 81 of file timer.h.
Referenced by Botan::Argon2_Family::tune(), Botan::Bcrypt_PBKDF_Family::tune(), and Botan::Scrypt_Family::tune().
|
inline |
|
inline |
|
inline |
bool Botan::Timer::operator< | ( | const Timer & | other | ) | const |
|
inline |
|
inline |
Definition at line 60 of file timer.h.
Referenced by Botan::Argon2_Family::tune(), Botan::Bcrypt_PBKDF_Family::tune(), Botan::RFC4880_S2K_Family::tune(), and Botan::Scrypt_Family::tune().
|
inline |
|
inline |
void Botan::Timer::start | ( | ) |
Definition at line 44 of file timer.cpp.
References Botan::OS::get_cpu_cycle_counter(), Botan::OS::get_system_timestamp_ns(), and stop().
void Botan::Timer::stop | ( | ) |
Definition at line 50 of file timer.cpp.
References Botan::OS::get_cpu_cycle_counter(), and Botan::OS::get_system_timestamp_ns().
Referenced by start().
std::string Botan::Timer::to_string | ( | ) | const |
Definition at line 87 of file timer.cpp.
References buf_size().
|
inline |
|
inline |
Definition at line 66 of file timer.h.
Referenced by Botan::Argon2_Family::tune(), Botan::Bcrypt_PBKDF_Family::tune(), and Botan::Scrypt_Family::tune().