I use the latest version of MKL(mkl 2017.0.109), and tested the TR(trust-region) solver (with or without constraints) with the same codes in both windows 7 (sp1) and windows 10 (enterprise). I found the solver is five times slower in windows 10. Anyone has any idea? Thank you.
I just used the MKL example "nonlinear least square problem with boundary constraints" and looped 1000 times.
The running time in windows 10 is 3591ms, and 572ms in windows 7. The code snippet is listed below,
extern int Calc();
int n = 1000;
clock_t t1, t2;
t1 = clock(); // system clock
for (int i = 0; i < n; ++i)
Calc(); // invoke the MKL example
t2 = clock();
float diff = t2 - t1;
cout << "elapsed time " << diff << endl;
The running time difference is pretty consistent and easy to reproduce. Thanks a lot.
ok, i see what you did.
1. This example contains different declaration, initialization, output and computation stages. The computation intensive part of this solution is dtrnlspbc_solve() routine. Could you check this part?
2. And using dsecnd() mkl's routine would give you more consistent results. see into RF for more details how to call this function.
OK. I inserted desecnd() function to calculate the elapsed time of each loop for the same MKL example. The part of codes is listed here. The lower left picture is from windows 10, and the right from windows 7. The running time difference for the core computation routine is significant, and it is about 6-7 times.