* Possible typo in madvise(2)
@ 2014-03-27 23:16 Alex Roper
[not found] ` <5334B14B.7070409-63aXycvo3TyHXe+LvDLADg@public.gmane.org>
0 siblings, 1 reply; 4+ messages in thread
From: Alex Roper @ 2014-03-27 23:16 UTC (permalink / raw)
To: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w; +Cc: linux-man-u79uwXL29TY76Z2rM5mHXA
Version: Current git repo
The first paragraph of DESCRIPTION states that madvise does not change
the semantics of an application except in the case of MADV_DONTNEED,
which I believe should read MADV_DONTFORK.
Thanks,
Alex
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 4+ messages in thread[parent not found: <5334B14B.7070409-63aXycvo3TyHXe+LvDLADg@public.gmane.org>]
* Re: Possible typo in madvise(2) [not found] ` <5334B14B.7070409-63aXycvo3TyHXe+LvDLADg@public.gmane.org> @ 2014-04-01 18:18 ` Michael Kerrisk (man-pages) [not found] ` <533B0303.2000601-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> 0 siblings, 1 reply; 4+ messages in thread From: Michael Kerrisk (man-pages) @ 2014-04-01 18:18 UTC (permalink / raw) To: Alex Roper Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w, linux-man-u79uwXL29TY76Z2rM5mHXA On 03/28/2014 12:16 AM, Alex Roper wrote: > Version: Current git repo > > The first paragraph of DESCRIPTION states that madvise does not change > the semantics of an application except in the case of MADV_DONTNEED, > which I believe should read MADV_DONTFORK. Alex, MADV_DONTNEED does change the semantics. But, could you say more about wht you think MADV_DONTFORK should have been written here instead? (Perhaps some fix is needed to the page.) Thanks, Michael -- Michael Kerrisk Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/ Linux/UNIX System Programming Training: http://man7.org/training/ -- To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <533B0303.2000601-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>]
* Re: Possible typo in madvise(2) [not found] ` <533B0303.2000601-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> @ 2014-04-01 19:22 ` Alex Roper [not found] ` <533B120E.1090406-63aXycvo3TyHXe+LvDLADg@public.gmane.org> 0 siblings, 1 reply; 4+ messages in thread From: Alex Roper @ 2014-04-01 19:22 UTC (permalink / raw) To: Michael Kerrisk (man-pages); +Cc: linux-man-u79uwXL29TY76Z2rM5mHXA Sorry for my confusion. Checking other sources I see MADV_DONTNEED results in modifications to private mappings being lost (the section on zero-filling non-file-backed pages address this, in retrospect) which clearly changes semantics. I had noticed that MADV_DONTFORK can result in different behavior after a fork (eg, a parent mmaps a file, madvises dontfork, then forks, and the child writes to the page -- with madvise, the page is updated, visible to both processes, as is the backing file, without it the child will segfault) and thought there might be a simple typo. Alex On 04/01/2014 02:18 PM, Michael Kerrisk (man-pages) wrote: > On 03/28/2014 12:16 AM, Alex Roper wrote: >> Version: Current git repo >> >> The first paragraph of DESCRIPTION states that madvise does not change >> the semantics of an application except in the case of MADV_DONTNEED, >> which I believe should read MADV_DONTFORK. > > Alex, > > MADV_DONTNEED does change the semantics. But, could you say more > about wht you think MADV_DONTFORK should have been written here > instead? (Perhaps some fix is needed to the page.) > > Thanks, > > Michael > -- To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <533B120E.1090406-63aXycvo3TyHXe+LvDLADg@public.gmane.org>]
* Re: Possible typo in madvise(2) [not found] ` <533B120E.1090406-63aXycvo3TyHXe+LvDLADg@public.gmane.org> @ 2014-04-01 19:25 ` Alex Roper 0 siblings, 0 replies; 4+ messages in thread From: Alex Roper @ 2014-04-01 19:25 UTC (permalink / raw) To: Michael Kerrisk (man-pages); +Cc: linux-man-u79uwXL29TY76Z2rM5mHXA > I had noticed that MADV_DONTFORK can result in different behavior after > a fork (eg, a parent mmaps a file, madvises dontfork, then forks, and > the child writes to the page -- with madvise, the page is updated, > visible to both processes, as is the backing file, without it the child > will segfault) and thought there might be a simple typo. Typo: I flipped with and without madvise cases here. -- To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-04-01 19:25 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-27 23:16 Possible typo in madvise(2) Alex Roper
[not found] ` <5334B14B.7070409-63aXycvo3TyHXe+LvDLADg@public.gmane.org>
2014-04-01 18:18 ` Michael Kerrisk (man-pages)
[not found] ` <533B0303.2000601-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-04-01 19:22 ` Alex Roper
[not found] ` <533B120E.1090406-63aXycvo3TyHXe+LvDLADg@public.gmane.org>
2014-04-01 19:25 ` Alex Roper
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).