Re: aio-core why not using SuS? [Re: [rfc] aio-core for 2.5.29 (Re: async-io API registration for 2.5.29)]

From: Martin J. Bligh (
Date: Fri Aug 16 2002 - 23:15:44 EST

>> At least some of those you don't have to kmap ... at least not in
>> the traditional sense. This sort of thing is a good application
>> for the per-process (or per-task) kernel virtual address area.
>> you just map in the stuff you need for your own task, instead
>> of having to share the global space with everybody.
> Careful.
> The VM space is shared _separately_ from other data structures, which
> means that you can _not_ user per-VM virtual address areas and expect them
> to scale with load. And than some VM happens to have thousands of threads,
> and you're dead.

OK ... not sure I understand the exact scenario you're evisioning,
but I can certainly see some problems in that area. There are two
different ways we could do this (or a combination of both), and I'm
not 100% sure if they solve the problems you mention, but it'd be
interesting to see what you think.

1. We have a per-process UKVA (user-kernel virtual address space),
which is great for per-process stuff like mapping pagetables. Dave
McCracken made an implementation of this that carves off a fixed
amount of space between the top of the stack and PAGE_OFFSET.
That makes highpte more efficient by saving the kmaps most of the
time (or it should).

2. A per task UKVA, that'd probably have to come out of something
like the vmalloc space. I think Bill Irwin derived something like
that from Dave's work, though I'm not sure it's complete & working
as yet. Per task things like the kernel stack (minus the task_struct
& waitqueues) could go in here.

> Kernel stacks most certainly can't do this easily, since you'll just hit
> the scalability problem somewhere else (ie many threads, same VM).

Does (2) solve some of the thread scalability problems you're worried
> And files, for example, can not only be many files for one VM, you can
> have the reverse too, ie many VM's, one file table.

Could we fix this by having multiple tasks map the same page and share
it? Still much less vaddr space overhead than global?

Hopefully I haven't totally missed your point ... if so, hit me again,
but harder and slower ;-)


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Fri Aug 23 2002 - 22:00:13 EST