Re: Any reason for passing "tlb" to "free_pgtables()" by address?

Nick Piggin
2006-05-09T01:40:02Z

Zoltan Menyhart wrote:

> Hugh Dickins wrote:
>
>> Personally I'd prefer not to make your change right now - it seems
>> a shame to make that cosmetic change without addressing the real
>> latency issue; but I've no strong feeling against your patch.
>
>
> Could you please explain what your plans are?

Long term, we would like to make the mmu_gather paths preemptible and
reentrant so the latency hacks can go away, and we don't end up with
awful things like a tlb flush after unmapping every 8 pages for
CONFIG_PREEMPT.

I posted a quick RFC a while back to implement my "gather in place"
idea: http://www.ussg.iu.edu/hypermail/linux/kernel/0603.2/0499.html

Hugh has a different approach, but neither is particularly urgent at
this stage.

In the short term, we might still like to be able to do latency breaks
in free_pgtables so it would make sense to keep the code the way it is.

>
> How much do you think it is worth to optimize "free_pgtables()",
> knowing that:
> - PTE, PMD and PUD pages are freed seldom (wrt. the leaf pages)
> - The number of these pages is much more less than
> that of the leaf pages.

Virtual address space can still be vast and sparse. Even with 32 bits,
we could probably trigger high latencies here.

Nick
--

Send instant messages to your online friends http://au.messenger.yahoo.com