From b0dd22cc7271523ba83d2bc8a85504b8445587b5 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Tue, 3 Feb 2009 19:05:10 +0000 Subject: [PATCH] update cholesky benchmark --- bench/benchCholesky.cpp | 41 +++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/bench/benchCholesky.cpp b/bench/benchCholesky.cpp index e998d8536..6772b86cc 100644 --- a/bench/benchCholesky.cpp +++ b/bench/benchCholesky.cpp @@ -9,7 +9,7 @@ // -DSCALAR=double #include -#include +#include #include using namespace Eigen; @@ -76,7 +76,8 @@ __attribute__ ((noinline)) void benchLLT(const MatrixType& m) else std::cout << "fixed "; std::cout << covMat.rows() << " \t" - << (timerNoSqrt.value() * REPEAT) / repeats << "s \t" + << (timerNoSqrt.value() * REPEAT) / repeats << "s " + << "(" << 1e-6 * cost*repeats/timerNoSqrt.value() << " MFLOPS)\t" << (timerSqrt.value() * REPEAT) / repeats << "s " << "(" << 1e-6 * cost*repeats/timerSqrt.value() << " MFLOPS)\n"; @@ -88,7 +89,7 @@ __attribute__ ((noinline)) void benchLLT(const MatrixType& m) gsl_matrix* gslCovMat = gsl_matrix_alloc(covMat.rows(),covMat.cols()); gsl_matrix* gslCopy = gsl_matrix_alloc(covMat.rows(),covMat.cols()); - + eiToGsl(covMat, &gslCovMat); for (int t=0; t0; ++i) +// benchLLT(Matrix(dynsizes[i],dynsizes[i])); - for (uint i=0; dynsizes[i]>0; ++i) - benchLLT(Matrix(dynsizes[i],dynsizes[i])); - -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); -// benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); + benchLLT(Matrix()); return 0; }