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 WAA00153; Mon, 28 Jun 2004 22:26:15 +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 WAA00142; Mon, 28 Jun 2004 22:26:13 +0200 (MET DST) Received: from postfix4-2.free.fr (postfix4-2.free.fr [213.228.0.176]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i5SKQCEV024733; Mon, 28 Jun 2004 22:26:13 +0200 Received: from univ-savoie.fr (grenoble-1-62-147-75-88.dial.proxad.net [62.147.75.88]) by postfix4-2.free.fr (Postfix) with ESMTP id 06A741983BC; Mon, 28 Jun 2004 22:26:09 +0200 (CEST) Message-ID: <40E0D34C.2040808@univ-savoie.fr> Date: Mon, 28 Jun 2004 22:26:20 -0400 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: Xavier Leroy Cc: caml-list Subject: Re: [Caml-list] Thread and kernel 2.6 pb still there in CVS References: <20040624194603.2A91010EF06@clark.cs.brown.edu> <1088158825.1941.113.camel@pelican.wigram> <20040625110748.GB2707@bourg.inria.fr> <1088166608.1941.120.camel@pelican.wigram> <40DC38D3.4010009@univ-savoie.fr> <20040628150805.GC7353@yquem.inria.fr> In-Reply-To: <20040628150805.GC7353@yquem.inria.fr> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Miltered: at nez-perce with ID 40E07EE4.000 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 vouillon's:01 bug:01 bug:01 andrieu:01 kernels:01 sched:01 omitted:01 conducting:99 sched:01 threads:01 developpers:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Xavier Leroy wrote: >>I tried to submit a change in vouillon's entry in the bug tracking >>system (classed as not a bug because can not reproduce), but as I am not >>sure it worked, So I also post this here > > > You should be grateful to Olivier Andrieu, who actually cared to > submit a bug report along with useful info on 2.6 kernels. > Sorry, but I thought continuing an entry in the bug tracking was better than adding one (but I was unable tu actually make a comment in that entry !) > The question I'm currently investigating is whether the call to > sched_yield() can be omitted, as it's just a scheduling hint. Initial > experiments suggested that this would hurt fairness (in Caml thread > scheduling) quite a lot on all platforms other than Linux 2.6. > More careful experiments that I'm currently conducting suggest that it > might not be so bad. One can also play games where sched_yield() > isn't called if there are no other Caml threads waiting for the global > Caml mutex. Someone (I do not remember who) suggested a call to select in place of sched_yield. My thought about semantics in that - a system call saying schedule just now or later (like the semantics of sched_yield in 2.4) only lower the percentage of CPU a thread get, except if you manage to have your thread "in phase" (I do not know if this is proper english) with the scheduler. Then to lower your % of CPU you should use renice (but I do not know if the semantics of renice is per thread or per processus). However a system call saying "I do not not need CPU for a while" could be usefull ... but it should have another name not to break existing program ... and should have an (optional ?) argument saying how long is this while. So I think the 2.6 developper are right, but should have created a new system call. and let sched yield unchanged. Any one can feel free to forward my post to a kernel developpers list :-) > In summary, a solution will eventually be found, but please be > patient, and submit a bug report next time. > > - Xavier Leroy -- 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 --------------------------------------------- ------------------- 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