/*************************************** Auteur : Pierre Aubert Mail : aubertp7@gmail.com Licence : CeCILL-C ****************************************/ #include #include "micro_benchmark.h" #include "PTensor.h" #include "hadamard.h" ///Get the number of nanoseconds per elements /** @param nbElement : number of elements of the tables */ void evaluateHadamardProduct(size_t nbElement){ PTensor tabX(AllocMode::ALIGNED, nbElement); PTensor tabY(AllocMode::ALIGNED, nbElement); PTensor tabRes(AllocMode::ALIGNED, nbElement); for(size_t i(0lu); i < nbElement; ++i){ tabX[i] = i*19lu%11; tabY[i] = i*27lu%19; } micro_benchmarkAutoNsPrint("evaluate hadamard", nbElement, hadamard_product, tabRes.getData(), tabX.getData(), tabY.getData(), nbElement); } int main(int argc, char** argv){ return micro_benchmarkParseArg(argc, argv, evaluateHadamardProduct); }