From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=AWL,SPF_FAIL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by yquem.inria.fr (Postfix) with ESMTP id E50ADBB84 for ; Mon, 12 Jan 2009 21:12:20 +0100 (CET) X-IronPort-AV: E=Sophos;i="4.37,254,1231110000"; d="scan'208";a="22364952" Received: from discorde.inria.fr ([192.93.2.38]) by mail1-smtp-roc.national.inria.fr with ESMTP; 12 Jan 2009 21:12:20 +0100 Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id n0CKCKXv022822 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Mon, 12 Jan 2009 21:12:20 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AnUDAFcza0lQRFuwgWdsb2JhbACUFAEBFiK/UIVv X-IronPort-AV: E=Sophos;i="4.37,254,1231110000"; d="scan'208";a="22364951" Received: from furbychan.cocan.org ([80.68.91.176]) by mail1-smtp-roc.national.inria.fr with ESMTP/TLS/AES256-SHA; 12 Jan 2009 21:12:20 +0100 Received: from rich by furbychan.cocan.org with local (Exim 4.63) (envelope-from ) id 1LMT91-0005kn-TR; Mon, 12 Jan 2009 20:12:19 +0000 Date: Mon, 12 Jan 2009 20:12:19 +0000 To: John Lepikhin Cc: caml-list@inria.fr Subject: Re: [Caml-list] Re: memory usage Message-ID: <20090112201219.GB21039@annexia.org> References: <1231746106.4376.27.camel@john-laptop> <20090112083913.GA28059@annexia.org> <1231751641.4376.39.camel@john-laptop> <1231759695.4376.55.camel@john-laptop> <20090112114127.GA1568@annexia.org> <1231782999.4376.246.camel@john-laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1231782999.4376.246.camel@john-laptop> User-Agent: Mutt/1.5.13 (2006-08-11) From: Richard Jones X-Miltered: at discorde with ID 496BA424.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; 2009:98 threads:01 wrote:01 unix:01 unix:01 caml-list:01 short:01 short:01 data:02 kernel:02 let:03 let:03 dev:04 dev:04 tue:06 On Tue, Jan 13, 2009 at 01:56:39AM +0800, John Lepikhin wrote: > > I'm afraid to say that you'll have to post a short reproducer here > > before I can look at this further ... > > I'm not sure this is the same issue. Look at this test code: For reasons I don't fully understand, this code doesn't seem to do anything. A print statement after the Unix.openfile is never printed. > let read_data _ = > let fd = Unix.openfile "/dev/random" [] 0o644 in You probably want to use something like /dev/urandom or /dev/zero here. This blocks after a very short time because /dev/random (on Linux) only produces characters while there is entropy in the kernel. (Not for very long once you start reading blocks of it from 20 threads). Rich. -- Richard Jones Red Hat