Re: [PATCH 2/3] mm: introduce fincore()

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

 



Hello Dave,

On Mon, Jun 02, 2014 at 09:11:37AM -0700, Dave Hansen wrote:
> On 06/01/2014 10:24 PM, Naoya Horiguchi wrote:
> > Detail about the data format being passed to userspace are explained in
> > inline comment, but generally in long entry format, we can choose which
> > information is extraced flexibly, so you don't have to waste memory by
> > extracting unnecessary information. And with FINCORE_SKIP_HOLE flag,
> > we can skip hole pages (not on memory,) which makes us avoid a flood of
> > meaningless zero entries when calling on extremely large (but only few
> > pages of it are loaded on memory) file.
> 
> Something similar could be useful for hugetlbfs too.  For a 1GB page,
> it's pretty silly to do 2^18 entries which essentially repeat the same
> data in an interface like this.

Good point.
For hugetlbfs file, we link a hugepage to pagecache at the index of
"hugepage" offset, so the second 1GB page in a hugetlbfs file are
linked to index 1, not 2^18. Current version of fincore() already
handle hugepage properly, so meaningless data copy doesn't happen.

Thanks,
Naoya Horiguchi

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>




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