Path: csiph.com!x330-a1.tempe.blueboxinc.net!aioe.org!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: Alexander Terekhov Newsgroups: comp.programming.threads Subject: Re: pthread question Date: Tue, 10 May 2011 17:53:27 +0200 Organization: A noiseless patient Spider Lines: 23 Message-ID: <4DC95F77.DAF3CBB4@web.de> References: <39abb345-ad69-453d-89da-29ee8e6e94f2@z15g2000prn.googlegroups.com> Reply-To: terekhov@web.de Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Injection-Info: mx02.eternal-september.org; posting-host="rjEYssPBnvQCB352RfJgNw"; logging-data="12126"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+msIlJG3637m9YH+glP3z9CwKpi+VGHdY=" X-Mailer: Mozilla 4.77 [en] (Windows NT 5.0; U) X-Accept-Language: en Cancel-Lock: sha1:pbRayBsnlcLIc2mCHOUR6picKYk= Xref: x330-a1.tempe.blueboxinc.net comp.programming.threads:136 Geoff Clare wrote: [...] > 9. When a running thread issues the sched_yield() function, the > thread becomes the tail of the thread list for its priority. That makes sense for a uniprocessor. But nowadays even pocket gadgets are multiprocessors. > POSIX doesn't standardise internals, but it does standardise how > threads with the above mentioned scheduling policies are scheduled. http://pubs.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_09.html "For application threads with scheduling allocation domains of size greater than one, the rules defined for SCHED_FIFO, SCHED_RR, [TSP] and SCHED_SPORADIC shall be used in an implementation-defined manner." Translation: no rules whatsoever. regards, alexander.