Re: Interesting VM feature?

From: Jamie Lokier
Date: Fri Aug 15 2003 - 16:19:58 EST


Mike Fedyk wrote:
> On Fri, Aug 15, 2003 at 02:56:02PM -0500, mouschi@xxxxxxxxx wrote:
> > Is madvise required to result in zero filled pages
> > by a standard, or is this just the commonly accepted
> > behavior?
>
> I believe it is the standard for clean pages, though someone else will have
> to point out where...

That's the answer to a different question.

The unanswered question is: what should madvise(MADV_DONTNEED) do,
given dirty pages?

man madvise(*) says that it zero-fills anonymous private mappings, and
restores private file-backed mappings to the original file pages.

That is not surprising, as the CPU-friendly semantic is more
complicated to implement, needing an extra flag in the page table
(or rmap structure).

-- Jamie
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/