Re: [PATCH] mm/memcontrol: avoid unnecessary PageTransHuge() when counting compound page

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 6, 2019 at 9:59 PM Michal Hocko <mhocko@xxxxxxxx> wrote:
>
> On Sun 05-05-19 14:40:57, Yafang Shao wrote:
> > If CONFIG_TRANSPARENT_HUGEPAGE is not set, hpage_nr_pages() is always 1;
> > if CONFIG_TRANSPARENT_HUGEPAGE is set, hpage_nr_pages() will
> > call PageTransHuge() to judge whether the page is compound page or not.
> > So we can use the result of hpage_nr_pages() to avoid uneccessary
> > PageTransHuge().
>
> The changelog doesn't describe motivation. Does this result in a better
> code/performance?
>

It is a better code, I think.
Regarding the performance, I don't think it is easy to measure.

Thanks
Yafang




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux