Re: [patch 1/3 take2] smaps: extract pte walker from smaps code

David Rientjes
2007-02-07T09:35:52Z

On Wed, 7 Feb 2007, Christoph Lameter wrote:

> Clearing reference bits? Ummm... That is a pretty inaccurate measure since
> reclaim can remove pages and revert the reference bits. It can never work
> reliably.
>

It's not intended to work precisely, it's intended to give a good estimate
of task memory footprint. There are several different scenarios that can
interfere with getting a precise measurement via this method; then again
/proc/pid/smaps is so expensive already because of the iteration through
VMA's that it's not something you'd do regularly.

Any other suggestions on how to obtain this data is certainly welcome.

> Would it be possible to sync up with the people doing the page table
> interface?
>

(+pauld)

Is there an update on Paul Davies' implementation that would allow us to
iterate through a set of pte's in a vm_area_struct range?

> Could we somehow consolidate smaps and numa_maps?
>

Sure, but that's beyond the scope of this patchset. My intention in
extracting away a new pte_walker was to prevent having two identical
implementations and it could easily be extracted even further to lib for
the ioremap case that Paul mentioned.

David