projects
/
platform
/
upstream
/
glibc.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
0a248aa18136e149cf8c719ecc223d121e8681ca
[platform/upstream/glibc.git]
/
time
/
clocktest.c
1
#include <stdio.h>
2
#include <time.h>
3
4
main ()
5
{
6
volatile int i;
7
double t1, t2, t;
8
9
t1 = (double) clock ();
10
for (i = 0; i < 100000; ++i) ;
11
t2 = (double) clock ();
12
13
t = (t2 - t1) / ((double) CLOCKS_PER_SEC);
14
printf ("%f - %f = %f\n",t2,t1,t);
15
return 0;
16
}