** Print the timing results. */
| 674 | ** Print the timing results. |
| 675 | */ |
| 676 | static void endTimer(FILE *out){ |
| 677 | if( enableTimer ){ |
| 678 | sqlite3_int64 iEnd = timeOfDay(); |
| 679 | struct rusage sEnd; |
| 680 | getrusage(RUSAGE_SELF, &sEnd); |
| 681 | sqlite3_fprintf(out, "Run Time: real %.3f user %f sys %f\n", |
| 682 | (iEnd - iBegin)*0.001, |
| 683 | timeDiff(&sBegin.ru_utime, &sEnd.ru_utime), |
| 684 | timeDiff(&sBegin.ru_stime, &sEnd.ru_stime)); |
| 685 | } |
| 686 | } |
| 687 | |
| 688 | #define BEGIN_TIMER beginTimer() |
| 689 | #define END_TIMER(X) endTimer(X) |
no test coverage detected