#include #include #include using namespace StormEigen; #ifndef REPEAT #define REPEAT 100000 #endif #ifndef TRIES #define TRIES 20 #endif typedef double Scalar; template __attribute__ ((noinline)) void bench_reverse(const MatrixType& m) { int rows = m.rows(); int cols = m.cols(); int size = m.size(); int repeats = (REPEAT*1000)/size; MatrixType a = MatrixType::Random(rows,cols); MatrixType b = MatrixType::Random(rows,cols); BenchTimer timerB, timerH, timerV; Scalar acc = 0; int r = internal::random(0,rows-1); int c = internal::random(0,cols-1); for (int t=0; t0; ++i) { bench_reverse(Matrix(dynsizes[i],dynsizes[i])); bench_reverse(Matrix(dynsizes[i]*dynsizes[i])); } // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); // bench_reverse(Matrix()); return 0; }