l4-hurd
[Top][All Lists]
Advanced

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

Re: task server


From: Marcus Brinkmann
Subject: Re: task server
Date: Thu, 07 Oct 2004 01:49:43 +0200
User-agent: Wanderlust/2.10.1 (Watching The Wheels) SEMI/1.14.6 (Maruoka) FLIM/1.14.6 (Marutamachi) APEL/10.6 Emacs/21.3 (i386-pc-linux-gnu) MULE/5.0 (SAKAKI)

At Wed, 06 Oct 2004 23:03:55 +0200,
Bas Wijnen <address@hidden> wrote:
> Unless the thread info of a task is in a static array in the capability 
> object, there must be some other table with the info present.

Ok, if it is for lookup and not storage purposes, you'd normally use a
hash table.  Task IDs will be allocated like PIDs (linearly, with wrap
around), to avoid early reusage), so they tend to get sparsely
distributed over time.  That's what libhurd-ihash is for.

> Anyway, my point was that the lookup of thread info (for creating or 
> destroying threads, for example) does not involve searching through a 
> list, so compared to getting a task info capability (which does involve 
> such a search) it is very fast.

I see.  Again, a hash table seems to do a better job.  I admit being
guilty of only skimming your code and missing the intended purpose of
the tables.

There is something that needs to be said about task death
notifications.  Notifications in L4 are an impossibility for us.  It's
simply not possible to implement them robustly and securely.
Everywhere where we are saying notifications, we actually mean some
sort of polling mechanism (a dedicated thread in the client polling
for new events).

This is all stuff that took us a long while to understand, and it's
still not fully understood in every detail.  So don't worry about it
if it doesn't make much sense to you.  We need to look at this in much
more detail (and with more foresight) to understand how it should be
implemented.  Not sure if I can do this before Praque's OpenWeekend
2004 (where I'll give a talk on the Hurd/L4).

Thanks,
Marcus






reply via email to

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