template<int Mode, typename MatrixType> void benchBasic_loop(const MatrixType& I, MatrixType& m, int iterations) __attribute__((noinline));
template<int Mode, typename MatrixType> void benchBasic_loop(const MatrixType& I, MatrixType& m, int iterations)
{ for(int a = 0; a < iterations; a++)
{ if (Mode==LazyEval)
{ asm("#begin_bench_loop LazyEval"); if (MatrixType::SizeAtCompileTime!=Eigen::Dynamic) asm("#fixedsize");
m = (I + 0.00005 * (m + m.lazyProduct(m))).eval();
} elseif (Mode==OmpEval)
{ asm("#begin_bench_loop OmpEval"); if (MatrixType::SizeAtCompileTime!=Eigen::Dynamic) asm("#fixedsize");
m = (I + 0.00005 * (m + m.lazyProduct(m))).eval();
} else
{ asm("#begin_bench_loop EarlyEval"); if (MatrixType::SizeAtCompileTime!=Eigen::Dynamic) asm("#fixedsize");
m = I + 0.00005 * (m + m * m);
} asm("#end_bench_loop");
}
}
template<int Mode, typename MatrixType> double benchBasic(const MatrixType& mat, int size, int tries) __attribute__((noinline));
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.