8 #ifndef OPENFPM_DATA_SRC_VECTOR_VECTOR_PERFORMANCE_TEST_HPP_
9 #define OPENFPM_DATA_SRC_VECTOR_VECTOR_PERFORMANCE_TEST_HPP_
11 #define NADD 128*128*128
16 BOOST_AUTO_TEST_CASE(vector_add_performance)
18 std::vector<double> times(N_STAT + 1);
21 for (
size_t j = 0 ; j < 8 ; j++)
23 for (
size_t i = 1 ; i < N_STAT+1 ; i++)
54 for (
size_t i = 0 ; i < NADD ; i++)
62 std::sort(times.begin(),times.end());
67 testsv.add(
"Vector add");
68 per_timesv.add(times[0]);
73 BOOST_AUTO_TEST_CASE(vector_performance_write_report)
78 std::cout <<
"Write vector report\n";
81 std::string per_dir(test_dir);
83 load_and_combine(per_dir + std::string(
"/openfpm_data/previous_measurev"),y,per_timesv);
88 for (
size_t j = 0; j < y.get(0).
size(); j++)
89 yn.add(
"config " + std::to_string(j));
95 options.
title = std::string(
"Vector Performances");
96 options.
yAxis = std::string(
"Time (seconds)");
97 options.
xAxis = std::string(
"Benchmark");
98 options.
stype = std::string(
"bars");
100 cg.addHTML(
"<h2>Vector performance test</h2>");
101 cg.AddHistGraph(testsv,y,yn,options);
void setz(T z_)
set the z property
std::string title
Title of the chart.
double getwct()
Return the elapsed real time.
std::string yAxis
Y axis name.
void setx(T x_)
set the x property
void start()
Start the timer.
boost::fusion::result_of::at< type, boost::mpl::int_< i > >::type get()
getter method for a general property i
void sets(T s_)
set the s property
void sety(T y_)
set the y property
static const unsigned int t
t property is at position 5 in the boost::fusion::vector
Test structure used for several test.
static const unsigned int v
v property is at position 4 in the boost::fusion::vector
std::string xAxis
X axis name.
Class for cpu time benchmarking.
void stop()
Stop the timer.