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 HAA04247; Wed, 14 Apr 2004 07:55:24 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id HAA04235 for ; Wed, 14 Apr 2004 07:55:23 +0200 (MET DST) Received: from post.bourget.univ-savoie.fr (post.bourget.univ-savoie.fr [193.48.120.73]) by concorde.inria.fr (8.12.10/8.12.10) with ESMTP id i3E5tLYM027965 for ; Wed, 14 Apr 2004 07:55:22 +0200 Received: from univ-savoie.fr (d85.lama.univ-savoie.fr [193.48.123.85]) by post.bourget.univ-savoie.fr (8.12.3/jtpda-5.4) with ESMTP id i3E5wjkh006574 ; Wed, 14 Apr 2004 07:58:46 +0200 Message-ID: <407CD31D.5080001@univ-savoie.fr> Date: Wed, 14 Apr 2004 07:58:53 +0200 From: Christophe Raffalli User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040115 X-Accept-Language: en-us, en MIME-Version: 1.0 To: David Brown Subject: Re: [Caml-list] Scheduling thread problem kernel 2.6 References: <407B9D6F.70800@univ-savoie.fr> <20040413194854.GB27613@davidb.org> In-Reply-To: <20040413194854.GB27613@davidb.org> X-Enigmail-Version: 0.83.3.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig602ACB5F6767A6B669FF4F7C" Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.33 (www . roaringpenguin . com / mimedefang) X-Miltered: at concorde by Joe's j-chkmail ("http://j-chkmail.ensmp.fr")! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; raffalli:01 raffalli:01 univ-savoie:01 caml-list:01 openpgp:01 2440:01 3156:01 2004:99 caml-list:01 threads:01 wrappers:01 wrappers:01 runtime:01 retaining:01 savoie:01 X-Attachments: type="application/pgp-signature" name="signature.asc" name="signature.asc" Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk X-Status: X-Keywords: X-UID: 300 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig602ACB5F6767A6B669FF4F7C Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit David Brown wrote: > On Tue, Apr 13, 2004 at 09:57:35AM +0200, Christophe Raffalli wrote: > >>Message posted to comp.os.linux.misc and caml-list. >> >>I am having a scheduling problem with a Caml program that uses two threads: >>- one CPU intensive thread >>- one interface thread (using Glut + OpenGL) and often doing nothing > > > What wrappers are you using to call to the interface. Are there any > blocking calls in it? You might check the wrappers to these calls to > make sure that they call enter_blocking_section, and > leave_blocking_section. Otherwise, the entire ocaml runtime will be > blocked. I do not understand ? First I launch the interface thread from Caml with Thread.create and the interface thread calls Glut.main_loop which never ends (except when the program terminates). This main loop call some Caml functions. The interface thread (which is the main thread) is affected a lot may be because the main_loop sleep while retaining a mutex blocking the computing thread. This is hat you mean ? > Dave -- Christophe Raffalli Université de Savoie Batiment Le Chablais, bureau 21 73376 Le Bourget-du-Lac Cedex tél: (33) 4 79 75 81 03 fax: (33) 4 79 75 87 42 mail: Christophe.Raffalli@univ-savoie.fr www: http://www.lama.univ-savoie.fr/~RAFFALLI --------------------------------------------- IMPORTANT: this mail is signed using PGP/MIME At least Enigmail/Mozilla, mutt or evolution can check this signature --------------------------------------------- --------------enig602ACB5F6767A6B669FF4F7C Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFAfNMdSQDyWB/+xBwRApYWAJ9u6ruIY7BKRY6YP+XUcrC/LZPfZwCgvf4f 2i6Ugb9G4+gjhfo81PlKPBw= =Gj7W -----END PGP SIGNATURE----- --------------enig602ACB5F6767A6B669FF4F7C-- ------------------- 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