12 #ifndef SPROCKIT_COMMON_UNITS_H_INCLUDED 13 #define SPROCKIT_COMMON_UNITS_H_INCLUDED 23 multiply64(int64_t a, int64_t b,
bool &errorflag);
27 std::map<std::string, int64_t> &fullname);
30 get_bandwidth(
const char *value,
bool &errorflag,
bool print_errors =
false);
36 get_frequency(
const char* value,
bool& errorflag,
bool print_errors =
false);
39 byte_length(
const char* value,
bool& errorflag,
bool print_errors =
false);
50 get_timestamp(
const char *value,
bool &errorflag,
bool print_errors =
false);
long byte_length(const char *value, bool &errorflag, bool print_errors=false)
double get_timestamp(const char *value, bool &errorflag, bool print_errors=false)
Get a timestamp possiblly suffixed with any of the identifiers psec, nsec, usec, msec, sec, ps, ns, us, ms, s.
int64_t multiply64(int64_t a, int64_t b, bool &errorflag)
Multiply two 64 bit integer values and check for overflow.
void populate_timestamp_names(std::map< std::string, int64_t > &value)
double get_frequency(const char *value, bool &errorflag, bool print_errors=false)
void populate_frequency_names(std::map< std::string, int64_t > &value)
void populate_bandwidth_names(std::map< std::string, int64_t > &abbrname, std::map< std::string, int64_t > &fullname)
double get_bandwidth(const char *value, bool &errorflag, bool print_errors=false)