To: lebotlan at beaune.inria.fr Cc: lablgtk at kaba.or.jp Subject: Re: Build and thread problem. In-Reply-To: <3CD2B6B1.5F548013 at beaune.inria.fr> References: <3CC961AF.2076EFF2 at beaune.inria.fr> <20020427000319V.garrigue@kurims.kyoto-u.ac.jp> <3CD2B6B1.5F548013@beaune.inria.fr> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20020507185832T.garrigue at kurims.kyoto-u.ac.jp> Date: Tue, 07 May 2002 18:58:32 +0900 From: Jacques Garrigue Lines: 28 From: Didier Le Botlan > I used bytecode threads, and while it worked perfectly in a short > test-program, a new-born thread takes more than 30 seconds to start. > > Then, I compiled ocaml with -with-pthreads. > My test program works perfectly (bytecode and native). > Under lablgtk, the bytecode version works poorly : > It is slower than it should be. > When I click another button (which does nothing : its handler is fun () > -> ()), the thread runs a little bit faster, then slowlier until the > next click. > > Here is what I observe with the native version : > When I launch a new thread, nothing happens (it can last for 30 > seconds, perhaps more). > As soon as I click another button (again a useless button), the thread > is launched and runs for a short time, then stops until I click again on > the same useless-button. All this looks pretty strange. Are you sure you are using GtkThread.main? (Not GMain.main!) And never creating another main loop? The only way to solve it is for you to send me some code that triggers the problem. Jacques