2005-11-07 17:08:44

by Chris Friesen

[permalink] [raw]
Subject: scheduler parameter inheritance on clone()


The pthreads standard specifies that the default behaviour is that new
threads should be created with the SCHED_OTHER policy and a priority of 0.

However, it appears that the kernel will create new tasks (be they
threads or processes) with the same settings as the parent.

If CLONE_THREAD is set, should the kernel perhaps set the policy and
priority as specified by pthreads?

Chris


2005-11-07 18:25:59

by Chris Friesen

[permalink] [raw]
Subject: Re: scheduler parameter inheritance on clone() -- correction

Friesen, Christopher [CAR:VC21:EXCH] wrote:
>
> The pthreads standard specifies that the default behaviour is that new
> threads should be created with the SCHED_OTHER policy and a priority of 0.

Sorry, I've since found out that this was actually an issue with the man
pages (same problem on two different distros). The man pages were still
from LinuxThreads, but the NPTL behaviour was different.

Apparently the spec doesn't actually specify the default behaviour, it's
implementation dependent.

My mistake.

Chris