lkml.org 
[lkml]   [2011]   [Feb]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [RFC][PATCH 3/6] break out smaps_pte_entry() from smaps_pte_range()
From
Date
On Thu, 2011-02-03 at 13:22 -0800, David Rientjes wrote:
> On Mon, 31 Jan 2011, Dave Hansen wrote:
> > We will use smaps_pte_entry() in a moment to handle both small
> > and transparent large pages. But, we must break it out of
> > smaps_pte_range() first.
>
> The extraction from smaps_pte_range() looks good. What's the performance
> impact on very frequent consumers of /proc/pid/smaps, though, as the
> result of the calls throughout the iteration if smaps_pte_entry() doesn't
> get inlined (supposedly because you'll be reusing the extracted function
> again elsewhere)?

We could try and coerce it in to always inlining it, I guess. I just
can't imagine this changes the cost _that_ much. Unless I have some
specific concers, I tend to leave this up to the compiler, and none of
the users look particularly fastpathy or performance sensitive to me.

...
> > - }
> > + pte = pte_offset_map_lock(vma->vm_mm, pmd, addr, &ptl);
> > + for (; addr != end; pte++, addr += PAGE_SIZE)
> > + smaps_pte_entry(*pte, addr, walk);
> > pte_unmap_unlock(pte - 1, ptl);
> > cond_resched();
> > return 0;
> > diff -puN mm/huge_memory.c~break-out-smaps_pte_entry mm/huge_memory.c
> > _
>
> Is there a missing change to mm/huge_memory.c?

Nope, it was just more of those empty diffs like in the last patch.
It's cruft from patch-scripts and some code that I use to ensure I don't
miss file edits when making patches. I'll pull them out.

-- Dave



\
 
 \ /
  Last update: 2011-02-03 22:43    [W:0.074 / U:0.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site