From: David Mosberger <davidm@napali.hpl.hp.com>
To: linux-ia64@vger.kernel.org
Subject: Re: Virtual memory leaking through IA32 emulation layer for mmap and munmap
Date: Tue, 09 Mar 2004 01:04:47 +0000 [thread overview]
Message-ID: <16461.6191.949155.778550@napali.hpl.hp.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0403091028060.22838@sutekh.progsoc.uts.edu.au>
>>>>> On Tue, 9 Mar 2004 11:57:47 +1100, Peter Chubb <peter@chubb.wattle.id.au> said:
>>>>> "David" = David Mosberger <davidm@napali.hpl.hp.com> writes:
David> Rounded up to the _page-size_ which is 4KB for x86. In
David> general, you can't just round up to 16KB for munmap() or all
David> hell will break lose.
Peter> As munmap()'s behaviour is undefined on memory that wasn't
Peter> allocated with mmap(), rounding to the underlaying true page
Peter> size should work for well-behaved programs.
Peter> x = mmap(... 4k ....) maps a 16k chunk
Peter> munmap(x, 4k) deallocates a 16k chunk, if page_size is
Peter> 16k
Peter> Of course at present, mmap32 tries to be clever and pretend
Peter> PAGE_SIZE is 4k, so it doesn't work...
All of this is old news and has come up at least twice in the past.
Don Dugger started to work on a patch to track partial page
allocations but I believe the patch was never finished. Please check
the mail archives for details.
--david
next prev parent reply other threads:[~2004-03-09 1:04 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-08 23:43 Virtual memory leaking through IA32 emulation layer for mmap and Shaun
2004-03-08 23:59 ` Virtual memory leaking through IA32 emulation layer for mmap and munmap H. J. Lu
2004-03-09 0:11 ` Peter Chubb
2004-03-09 0:23 ` David Mosberger
2004-03-09 0:26 ` Virtual memory leaking through IA32 emulation layer for mmap Shaun
2004-03-09 0:57 ` Virtual memory leaking through IA32 emulation layer for mmap and munmap Peter Chubb
2004-03-09 1:04 ` David Mosberger [this message]
2004-03-09 20:26 ` Virtual memory leaking through IA32 emulation layer for mmap Arun Sharma
2004-03-09 20:32 ` Arun Sharma
2004-03-10 3:58 ` Virtual memory leaking through IA32 emulation layer for mmap and munmap n0ano
2004-03-10 5:16 ` Virtual memory leaking through IA32 emulation layer for mmap Shaun
2004-03-10 17:47 ` David Mosberger
2004-03-10 19:35 ` Arun Sharma
2004-03-10 19:48 ` David Mosberger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=16461.6191.949155.778550@napali.hpl.hp.com \
--to=davidm@napali.hpl.hp.com \
--cc=linux-ia64@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox