[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: thread ids, task ids and subsystems

From: Marcus Brinkmann
Subject: Re: thread ids, task ids and subsystems
Date: Wed, 2 Apr 2003 20:01:52 +0200
User-agent: Mutt/1.5.3i

On Wed, Apr 02, 2003 at 07:22:03PM +0200, Volkmar Uhlig wrote:
> > The root server considers all threads with a subsystem of 0, or with a
> > thread number of 0 (masking out the subsystem bits) as privileged, and
> > allows those threads to control *any* other thread.  (This is 
> > important as you must be able to create, control and destroy one 
> > subsystem from another one for debugging and maintenance).  The root 
> > server itself does not need to keep any state: It just checks bits in 
> > the thread id.  The responsibility to manage thread numbers and
> version 
> > numbers is completely within the special 0 threads.  It also contains 
> > no mechanism to concurrently allocate unique subsystem ids, although 
> > that is something you might want in a real world system (but that
> could 
> > be added later).
> Marcus,
> having a single privileged thread will result in poor SMP performance,
> since you have to IPC cross processor. That will add significant latency
> to thread creation/deletion. You should therefore have one privileged
> HURD thread per physical processor.

Thanks for the tip.  I guess that is easy to add by just allowing the first
M threads in each subsystem to be privileged, and the normal thread numbers
start at M in each subsystem, where M is the number of processors.

However, I wonder if we are not safed by keeping a pool of threads in each
task.  If each task pre-allocates threads, maybe even with exponential
backoff, is it really that much of a problem?

Anyway, by not allowing a subsystem to have M privileged threads we are
enforcing a policy decision to them, so I think that making M privileged
threads possible is certainly a good idea.


`Rhubarb is no Egyptian god.' GNU      http://www.gnu.org    address@hidden
Marcus Brinkmann              The Hurd http://www.gnu.org/software/hurd/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]