[erlang-questions] writing a delay loop without now()

Jay Nelson jay@REDACTED
Sat Feb 21 18:04:01 CET 2009


Using an iBook G4 I get:

Erlang (BEAM) emulator version 5.6.4 [source] [async-threads:0]  
[hipe] [kernel-poll:false]

Eshell V5.6.4  (abort with ^G)

29> erlang:statistics(wall_clock),timer:sleep(1),erlang:statistics 
(wall_clock).
{987019,11}

30> erlang:statistics(wall_clock),timer:sleep(16),erlang:statistics 
(wall_clock).
{991049,17}

33> erlang:statistics(wall_clock),{test:time2 
(5000000),erlang:statistics(wall_clock)}.
{{4824884,5000000},{1008213,3634}}

34> erlang:statistics(wall_clock),{test:time2 
(5000000),erlang:statistics(wall_clock)}.
{{4939556,5000000},{1016268,3361}}


jay




More information about the erlang-questions mailing list