Re: deferred rss update instead of sloppy rss
From: Nick Piggin (nickpiggin_at_yahoo.com.au)
Date: 11/22/04
- Previous message: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- In reply to: Linus Torvalds: "Re: deferred rss update instead of sloppy rss"
- Next in thread: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- Reply: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 23 Nov 2004 09:32:48 +1100 To: Linus Torvalds <torvalds@osdl.org>
Linus Torvalds wrote:
>
> On Mon, 22 Nov 2004, Christoph Lameter wrote:
>
>>The problem is then that the proc filesystem must do an extensive scan
>>over all threads to find users of a certain mm_struct.
>
>
> The alternative is to just add a simple list into the task_struct and the
> head of it into mm_struct. Then, at fork, you just finish the fork() with
>
> list_add(p->mm_list, p->mm->thread_list);
>
> and do the proper list_del() in exit_mm() or wherever.
>
> You'll still loop in /proc, but you'll do the minimal loop necessary.
>
Yes, that was what I was thinking we'd have to resort to. Not a bad idea.
It would be nice if you could have it integrated with the locking that
is already there - for example mmap_sem, although that might mean you'd
have to take mmap_sem for writing which may limit scalability of thread
creation / destruction... maybe a seperate lock / semaphore for that list
itself would be OK.
Deferred rss might be a practical solution, but I'd prefer this if it can
be made workable.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Previous message: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- In reply to: Linus Torvalds: "Re: deferred rss update instead of sloppy rss"
- Next in thread: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- Reply: Christoph Lameter: "Re: deferred rss update instead of sloppy rss"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|