[erlang-questions] Erlang timer accuracy & precision

1 view
Skip to first unread message

G Bulmer

unread,
Sep 28, 2007, 7:34:56 PM9/28/07
to erlang-q...@erlang.org
I am writing some benchmarks, and I'd like to know what is the
accuracy and precision/sensitivity of the Erlang time mechanisms?
AFAIK I can use timer:tc(), statistics(wall_clock) and now() to get
wall-clock/real time.

I'm trying to understand if it makes any significant difference which
I use.

My questions are:
1. Are they all similar accuracy, or is one more accurate than the
others?
2. Is the aparent precision/sensitivity of (at least) a millisecond
really available from those time sources, or is there some mechanism
they use which is actually less precise/sensitive?
3. Are they all approximately the same cost, or is one typically
cheaper than another?

I'm using Mac OS X 10.4 on MacBook Pro (core 2 duo) and Linux 2.6.9-
smp (Centos 4.1) on Athlon 64 X2.

Supplementary question: does the answers to 1-3 change significantly
with newer versions of the Linux Kernel?
I'm able to move to a 'good' kernel, but preferably something on long
term support.

As ever, pointers, advice and suggestions are always welcome.
G Bulmer

PS - See you next week in Freiburg.

_______________________________________________
erlang-questions mailing list
erlang-q...@erlang.org
http://www.erlang.org/mailman/listinfo/erlang-questions

Reply all
Reply to author
Forward
0 new messages