From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id NAA13110; Sun, 6 Oct 2002 13:12:51 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id NAA12871 for ; Sun, 6 Oct 2002 13:12:50 +0200 (MET DST) Received: from smtp.noos.fr (verlaine.noos.net [212.198.2.73]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id g96BCnD02246 for ; Sun, 6 Oct 2002 13:12:49 +0200 (MET DST) Received: (qmail 14616459 invoked by uid 0); 6 Oct 2002 11:12:48 -0000 Received: from unknown (HELO noos.fr) ([81.65.61.57]) (envelope-sender ) by 212.198.2.73 (qmail-ldap-1.03) with SMTP for ; 6 Oct 2002 11:12:48 -0000 Message-ID: <3DA01AAF.14FD242C@noos.fr> Date: Sun, 06 Oct 2002 13:12:47 +0200 From: nadji@noos.fr X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.4.19-gentoo-r9 i686) X-Accept-Language: en MIME-Version: 1.0 To: "caml-list@inria.fr" Subject: [Caml-list] Native Threads Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Hi, I've just been playing with threads and I noticed at execution time that Thread.kill is not implemented by the posix-compiled version of the library. I used this flag because I thought that it would be faster (please correct me if I'm wrong), and there was no mention that Thread.kill would not be implemented. By looking at the sources, I learned that the reason is "problems with cleanup handlers on several platforms". That's fine with me, but I would like to compile my program :) So, would it be easy to add a flag to the byte code compiler to say that we want the full thread library ? Or, is there a workaround to simulate Thread.kill, without modifying the (function running as a)thread to kill (it could be doing a long system call) ? Or, does someone knows how to implement a function timeout: float -> (unit->unit) -> unit which executes the function given in argument , but no more than a certain amount of time, without Thread.kill ? TIA, Nadji ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners