-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Okay, I'm posting this at 3 in the morning -- I hope I am still
communicating understandably...
So say you want to get the process time consumed by a function or a
small program. Is it possible to get that value in nanoseconds?
Everything I read online says best we can do is microseconds, but then
most everything I find online is years old, so I thought I would double
check...
I found clock_t times(struct tms *buf) from <sys/times.h>, which returns
the number of "clock times", but on my system the CLOCKS_PER_SEC value
is 1000000, so I think that means microseconds is still the best we can
do. (Aside, of course, from running process many times and averaging the
results...)
- --
Christopher Howard
http://indicium.us
http://theologia.indicium.us
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAksXpeIACgkQQ5FLNdi0BcWwewCaA9TnnzchOb1XT9egAVLMQahN
WAYAn37sYBd4EP6bT3ZaJ1ty7X/kgPdo
=MNSt
-----END PGP SIGNATURE-----
---------
To unsubscribe, send email to <aklug-request@aklug.org>
with 'unsubscribe' in the message body.
Received on Thu Dec 3 02:50:06 2009
This archive was generated by hypermail 2.1.8 : Thu Dec 03 2009 - 02:50:06 AKST