From: Arun Sharma <arun.sharma@intel.com>
To: linux-ia64@vger.kernel.org
Subject: Re: Virtual memory leaking through IA32 emulation layer for mmap
Date: Tue, 09 Mar 2004 20:26:38 +0000 [thread overview]
Message-ID: <404E287E.30501@intel.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0403091028060.22838@sutekh.progsoc.uts.edu.au>
Peter Chubb wrote:
>
> As munmap()'s behaviour is undefined on memory that wasn't allocated
> with mmap(), rounding to the underlaying true page size should work
> for well-behaved programs.
>
> x = mmap(... 4k ....)
> maps a 16k chunk
>
> munmap(x, 4k)
> deallocates a 16k chunk, if page_size is 16k
As David said, this has been discussed before. Basically if there were
other 4k mappings with a different permission in the same 16k chunk, you
can't deallocate the 16k chunk safely. Tracking the sub pages without
changes to machine independent code (struct page) is possible, but may
be expensive.
-Arun
next prev parent reply other threads:[~2004-03-09 20:26 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
2004-03-09 20:26 ` Arun Sharma [this message]
2004-03-09 20:32 ` Virtual memory leaking through IA32 emulation layer for mmap 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=404E287E.30501@intel.com \
--to=arun.sharma@intel.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