![]() |
|
#include <iostream>
#include <cstdint>
#include <cstdlib>
#include <vector>
#include <fstream>
#include <memory>
#include <cstdio>
#include <Eigen/Core>
#include <bench/BenchTimer.h>
Classes | |
struct | size_triple_t |
struct | benchmark_t |
struct | action_t |
struct | human_duration_t |
struct | measure_all_pot_sizes_action_t |
struct | measure_default_sizes_action_t |
Typedefs | |
typedef MatrixXf | MatrixType |
typedef MatrixType::Scalar | Scalar |
typedef internal::packet_traits< Scalar >::type | Packet |
Functions | |
uint8_t | log2_pot (size_t x) |
uint16_t | compact_size_triple (size_t k, size_t m, size_t n) |
uint16_t | compact_size_triple (const size_triple_t &t) |
ostream & | operator<< (ostream &s, const benchmark_t &b) |
bool | operator< (const benchmark_t &b1, const benchmark_t &b2) |
void | print_cpuinfo () |
template<typename T > | |
string | type_name () |
template<> | |
string | type_name< float > () |
template<> | |
string | type_name< double > () |
void | show_usage_and_exit (int, char *argv[], const vector< unique_ptr< action_t >> &available_actions) |
float | measure_clock_speed () |
ostream & | operator<< (ostream &s, const human_duration_t &d) |
void | serialize_benchmarks (const char *filename, const vector< benchmark_t > &benchmarks, size_t first_benchmark_to_run) |
bool | deserialize_benchmarks (const char *filename, vector< benchmark_t > &benchmarks, size_t &first_benchmark_to_run) |
void | try_run_some_benchmarks (vector< benchmark_t > &benchmarks, double time_start, size_t &first_benchmark_to_run) |
void | run_benchmarks (vector< benchmark_t > &benchmarks) |
int | main (int argc, char *argv[]) |
Variables | |
bool | eigen_use_specific_block_size |
int | eigen_block_size_k |
int | eigen_block_size_m |
int | eigen_block_size_n |
static BenchTimer | timer |
const int | measurement_repetitions = 3 |
const float | min_accurate_time = 1e-2f |
size_t | min_working_set_size = 0 |
float | max_clock_speed = 0.0f |
const size_t | maxsize = 2048 |
const size_t | minsize = 16 |
const char | session_filename [] = "/data/local/tmp/benchmark-blocking-sizes-session.data" |
#define EIGEN_TEST_SPECIFIC_BLOCKING_SIZE_K eigen_block_size_k |
#define EIGEN_TEST_SPECIFIC_BLOCKING_SIZE_M eigen_block_size_m |
#define EIGEN_TEST_SPECIFIC_BLOCKING_SIZE_N eigen_block_size_n |
#define EIGEN_TEST_SPECIFIC_BLOCKING_SIZES eigen_use_specific_block_size |
typedef MatrixXf MatrixType |
typedef MatrixType::Scalar Scalar |
uint16_t compact_size_triple | ( | const size_triple_t & | t | ) |
References compact_size_triple(), and plotPSD::t.
uint16_t compact_size_triple | ( | size_t | k, |
size_t | m, | ||
size_t | n | ||
) |
bool deserialize_benchmarks | ( | const char * | filename, |
vector< benchmark_t > & | benchmarks, | ||
size_t & | first_benchmark_to_run | ||
) |
References MergeRestartFiles::filename, and max_clock_speed.
Referenced by run_benchmarks().
uint8_t log2_pot | ( | size_t | x | ) |
References calibrate::action, i, maxsize, measurement_repetitions, min_accurate_time, min_working_set_size, minsize, print_cpuinfo(), show_usage_and_exit(), and Eigen::internal::packet_traits< T >::size.
float measure_clock_speed | ( | ) |
Referenced by run_benchmarks(), and try_run_some_benchmarks().
bool operator< | ( | const benchmark_t & | b1, |
const benchmark_t & | b2 | ||
) |
References benchmark_t::compact_block_size, benchmark_t::compact_product_size, and benchmark_t::gflops.
Referenced by Eigen::TensorBase< Derived, ReadOnlyAccessors >::operator<().
ostream& operator<< | ( | ostream & | s, |
const benchmark_t & | b | ||
) |
ostream& operator<< | ( | ostream & | s, |
const human_duration_t & | d | ||
) |
References s, and human_duration_t::seconds.
void print_cpuinfo | ( | ) |
void run_benchmarks | ( | vector< benchmark_t > & | benchmarks | ) |
References deserialize_benchmarks(), i, Eigen::max(), max_clock_speed, measure_clock_speed(), session_filename, and try_run_some_benchmarks().
Referenced by measure_all_pot_sizes_action_t::run(), and measure_default_sizes_action_t::run().
void serialize_benchmarks | ( | const char * | filename, |
const vector< benchmark_t > & | benchmarks, | ||
size_t | first_benchmark_to_run | ||
) |
References MergeRestartFiles::filename, and max_clock_speed.
Referenced by try_run_some_benchmarks().
void show_usage_and_exit | ( | int | , |
char * | argv[], | ||
const vector< unique_ptr< action_t >> & | available_actions | ||
) |
Referenced by main().
void try_run_some_benchmarks | ( | vector< benchmark_t > & | benchmarks, |
double | time_start, | ||
size_t & | first_benchmark_to_run | ||
) |
References max_clock_speed, measure_clock_speed(), serialize_benchmarks(), and session_filename.
Referenced by run_benchmarks().
string type_name | ( | ) |
string type_name< float > | ( | ) |
int eigen_block_size_k |
Referenced by benchmark_t::run().
int eigen_block_size_m |
Referenced by benchmark_t::run().
int eigen_block_size_n |
Referenced by benchmark_t::run().
bool eigen_use_specific_block_size |
Referenced by benchmark_t::run().
float max_clock_speed = 0.0f |
Referenced by deserialize_benchmarks(), run_benchmarks(), serialize_benchmarks(), and try_run_some_benchmarks().
const size_t maxsize = 2048 |
Referenced by EIGEN_DECLARE_TEST(), main(), measure_all_pot_sizes_action_t::run(), and measure_default_sizes_action_t::run().
const int measurement_repetitions = 3 |
Referenced by main(), measure_all_pot_sizes_action_t::run(), and measure_default_sizes_action_t::run().
Referenced by main(), and benchmark_t::run().
size_t min_working_set_size = 0 |
Referenced by main(), and benchmark_t::run().
const size_t minsize = 16 |
Referenced by main(), measure_all_pot_sizes_action_t::run(), and measure_default_sizes_action_t::run().
const char session_filename[] = "/data/local/tmp/benchmark-blocking-sizes-session.data" |
Referenced by run_benchmarks(), and try_run_some_benchmarks().
|
static |