From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id 04937BB83 for ; Tue, 18 Jul 2006 15:30:19 +0200 (CEST) Received: from ka.univ-orleans.fr (ka.univ-orleans.fr [193.49.83.5]) by nez-perce.inria.fr (8.13.6/8.13.6) with ESMTP id k6IDUGgJ008908 for ; Tue, 18 Jul 2006 15:30:18 +0200 Received: from mailetu.univ-orleans.fr (localhost [127.0.0.1]) by ka.univ-orleans.fr (Postfix) with ESMTP id 9549512AD73; Tue, 18 Jul 2006 15:30:06 +0200 (CEST) Received: from localhost (etu [127.0.0.1]) by mailetu.univ-orleans.fr (Postfix) with ESMTP id 4F7228012; Tue, 18 Jul 2006 15:27:58 +0200 (CEST) Received: from 81.80.205.253 ([81.80.205.253]) by webmailetu.univ-orleans.fr (Horde MIME library) with HTTP; Tue, 18 Jul 2006 15:27:58 +0200 Message-ID: <20060718152758.crpucakwxhs80sk4@webmailetu.univ-orleans.fr> Date: Tue, 18 Jul 2006 15:27:58 +0200 From: Julien Michel To: Jean-Christophe Filliatre Cc: caml-list@yquem.inria.fr Subject: Re: [Caml-list] Unix module troubles & Time functions References: <20060718121035.hy7o1wa1cmhus4g0@webmailetu.univ-orleans.fr> <17596.52526.904011.898429@pc9-152.lri.fr> In-Reply-To: <17596.52526.904011.898429@pc9-152.lri.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Internet Messaging Program (IMP) H3 (4.0.3) X-Miltered: at nez-perce with ID 44BCE268.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; univ-orleans:01 unix:01 filliatre:01 filliatr:01 lri:01 unix:01 utime:01 utime:01 printf:01 printf:01 ocamlrun:01 caml-list:01 michel:01 michel:01 functions:01 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 Quoting Jean-Christophe Filliatre : > To do such a measurement, I'm using the Unix.times function, as > follows: > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > open Unix > > let utime f x =3D > let u =3D (times()).tms_utime in > let y =3D f x in > let ut =3D (times()).tms_utime -. u in > (y,ut) > > let print_utime f x =3D > let (y,ut) =3D utime f x in > Printf.printf "user time: %2.2f\n" ut; > y > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > Thanks for this piece of advice. Yet, I work on standalone bytcode files, executed with "ocamlrun" on the tar= get. So I can not use Unix functions just writing "open Unix" and calling some of= the functions it provides us. The problem remains the same: for the moment I am still not able to use the = Unix module. Any idea to fix that point? ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program.