| 105 | ++nloop; |
| 106 | } |
| 107 | void reportResult(const char* title) const { |
| 108 | if (nloop < 1) { |
| 109 | printf("%s(%s): no result\n",__func__,title); |
| 110 | return; |
| 111 | } |
| 112 | printf("============ %s\n",title); |
| 113 | printf("<dot> = %g\n",sum/nloop); |
| 114 | auto t = sumt/nloop, dt = sumt2/nloop - t*t; |
| 115 | if (dt > 0) dt = sqrt(dt); |
| 116 | printf("<time> = %g +/- %g us. Max. time = %g us.\n",t,dt,maxt); |
| 117 | } |
| 118 | }; |
| 119 | |
| 120 |