caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Re: timer
@ 1996-06-06 16:14 Robbert VanRenesse
  0 siblings, 0 replies; 4+ messages in thread
From: Robbert VanRenesse @ 1996-06-06 16:14 UTC (permalink / raw)
  To: Pierre Weis, caml-list


I have ported part of the Unix library to Windows.  It includes gettimeofday
and all the socket stuff.  I have to put some finishing touches on it, but
will make it available soon.  Unfortunately, I'm gone most of next week, and
very busy this week, but I'll see what I can do.

Robbert

At 09:09 AM 6/4/96 +0200, Pierre Weis wrote:
>
>Date: Mon, 3 Jun 1996 21:52:48 +0100
>To: caml-list@pauillac.inria.fr
>Subject: fonction pour mesurer le temps
>
>[English: there is no means to measure elapsed time in Caml Light under PC or
>Macintosh. Is there the necessary C code primitive already written somewhere ?]
>
>j'avais pose a P.W. la question suivante:
>
>> 1) d'un eleve: existe-t-il une fonction de bibliotheque pour mesurer le
>> temps ecoule?
>
>la reponse de P.W.:
>
>> Elle existe dans la librairie Unix. Sinon il faut e'crire un bout de
>> code C qui la procure...
>
>d'ou une nouvelle question, a destination de la liste: quelqu'un a-t-il
>ecrit cette fonction 1) pour caml-win 2) pour caml-dos 3) pour caml-mac ?
>ceci pour eviter de re-inventer la roue (qui tourne, arf).
>
>amicalement,
>
>Bruno Petazzoni <bpetazzoni@sancerre.ac-idf.jussieu.fr>
>Lyc. M. Berthelot
>94100 SAINT-MAUR
>
>
>
>






^ permalink raw reply	[flat|nested] 4+ messages in thread

* timer
@ 2005-01-03  1:58 Anastasia Gornostaeva
  0 siblings, 0 replies; 4+ messages in thread
From: Anastasia Gornostaeva @ 2005-01-03  1:58 UTC (permalink / raw)
  To: caml-list

Hello.

Does exist Timer module, that allows me add/reset/remove timed events?
Currently I use Unix.setitimer() for my simple implementation that allows
only adding new events into a queue, but my skills is not enough to implement
reset and remove events from the Timer queue.
And I'm not sure if using Unix.sleep() with setitimer() is safely (without
Threads).
Thanks.

ermine


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: timer
@ 1996-06-07 22:23 Doug Currie, Flavors Technology, Inc.
  0 siblings, 0 replies; 4+ messages in thread
From: Doug Currie, Flavors Technology, Inc. @ 1996-06-07 22:23 UTC (permalink / raw)
  To: caml-list; +Cc: Bruno Petazzoni


>[English: there is no means to measure elapsed time in Caml Light under PC or
>Macintosh. Is there the necessary C code primitive already written somewhere ?]

I did this for my Mac port of Caml Light 0.7 (which is not the official
port) and for Mac Moscow ML (which is the official port and is based on my
Mac Caml Light 0.7).

In my Mac Caml Light 0.7 and in Mac Moscow ML I implemented three timers:
- elapsed time
- time spent in GC
- time spent in "the cooperative multitasking experience"
and primitives to create additional timers.

To do this, macros to start and stop the various timers must be inserted in
many places in the runtime code. The Caml Light team decided not to include
my stuff, probably because so many changes were required in the source.

If you would like to see how it's done, get the Mac Moscow ML from
<http://www.dina.kvl.dk/~sestoft/mosml.html>. Look at the file runtime.c
and then look for uses of the macros beg_gc_time(), end_gc_time(),
beg_mf_time(), and end_mf_time(). gettimeofday is also implemented there in
e_gettimeofday.c.

e







^ permalink raw reply	[flat|nested] 4+ messages in thread

* timer
@ 1996-06-04  7:09 Pierre Weis
  0 siblings, 0 replies; 4+ messages in thread
From: Pierre Weis @ 1996-06-04  7:09 UTC (permalink / raw)
  To: caml-list


Date: Mon, 3 Jun 1996 21:52:48 +0100
To: caml-list@pauillac.inria.fr
Subject: fonction pour mesurer le temps

[English: there is no means to measure elapsed time in Caml Light under PC or
Macintosh. Is there the necessary C code primitive already written somewhere ?]

j'avais pose a P.W. la question suivante:

> 1) d'un eleve: existe-t-il une fonction de bibliotheque pour mesurer le
> temps ecoule?

la reponse de P.W.:

> Elle existe dans la librairie Unix. Sinon il faut e'crire un bout de
> code C qui la procure...

d'ou une nouvelle question, a destination de la liste: quelqu'un a-t-il
ecrit cette fonction 1) pour caml-win 2) pour caml-dos 3) pour caml-mac ?
ceci pour eviter de re-inventer la roue (qui tourne, arf).

amicalement,

Bruno Petazzoni <bpetazzoni@sancerre.ac-idf.jussieu.fr>
Lyc. M. Berthelot
94100 SAINT-MAUR





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-01-03  1:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-06-06 16:14 timer Robbert VanRenesse
  -- strict thread matches above, loose matches on Subject: below --
2005-01-03  1:58 timer Anastasia Gornostaeva
1996-06-07 22:23 timer Doug Currie, Flavors Technology, Inc.
1996-06-04  7:09 timer Pierre Weis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).