From: Cyrill Gorcunov <gorcunov@gmail.com>
To: Konstantin Khlebnikov <koct9i@gmail.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Linus Torvalds <torvalds@linux-foundation.org>
Subject: Re: [PATCH RFC] mm: rework virtual memory accounting
Date: Mon, 14 Dec 2015 12:08:27 +0300 [thread overview]
Message-ID: <20151214090827.GA14045@uranus> (raw)
In-Reply-To: <145008075795.15926.4661774822205839673.stgit@zurg>
On Mon, Dec 14, 2015 at 11:12:38AM +0300, Konstantin Khlebnikov wrote:
> Here several rated changes bundled together:
> * keep vma counting if CONFIG_PROC_FS=n, will be used for limits
> * replace mm->shared_vm with better defined mm->data_vm
> * account anonymous executable areas as executable
> * account file-backed growsdown/up areas as stack
> * drop struct file* argument from vm_stat_account
> * enforce RLIMIT_DATA for size of data areas
>
> This way code looks cleaner: now code/stack/data
> classification depends only on vm_flags state:
>
> VM_EXEC & ~VM_WRITE -> code (VmExe + VmLib in proc)
> VM_GROWSUP | VM_GROWSDOWN -> stack (VmStk)
> VM_WRITE & ~VM_SHARED & !stack -> data (VmData)
>
> The rest (VmSize - VmData - VmStk - VmExe - VmLib) could be called "shared",
> but that might be strange beasts like readonly-private or VM_IO areas.
>
> RLIMIT_AS limits whole address space "VmSize"
> RLIMIT_STACK limits stack "VmStk" (but each vma individually)
> RLIMIT_DATA now limits "VmData"
>
> Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com>
Looks OK to me. Lets wait for Linus' opinion.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2015-12-14 9:08 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-13 20:14 [RFC 1/2] [RFC] mm: Account anon mappings as RLIMIT_DATA Cyrill Gorcunov
2015-12-14 8:12 ` Konstantin Khlebnikov
2015-12-14 8:12 ` [PATCH RFC] mm: rework virtual memory accounting Konstantin Khlebnikov
2015-12-14 9:08 ` Cyrill Gorcunov [this message]
2015-12-14 14:51 ` [RFC 1/2] [RFC] mm: Account anon mappings as RLIMIT_DATA Quentin Casasnovas
2015-12-14 15:11 ` Cyrill Gorcunov
2015-12-14 15:32 ` Quentin Casasnovas
2015-12-14 15:43 ` Cyrill Gorcunov
2015-12-28 21:10 [PATCH RFC] mm: Rework virtual memory accounting Cyrill Gorcunov
2015-12-28 22:22 ` Linus Torvalds
2015-12-29 9:43 ` Cyrill Gorcunov
2016-01-22 19:42 ` Christian Borntraeger
2016-01-22 20:20 ` Cyrill Gorcunov
2016-01-22 20:21 ` Andrew Morton
2016-01-22 20:30 ` Linus Torvalds
2015-12-28 23:10 ` Andrew Morton
2015-12-29 9:48 ` Cyrill Gorcunov
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=20151214090827.GA14045@uranus \
--to=gorcunov@gmail.com \
--cc=koct9i@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=torvalds@linux-foundation.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;
as well as URLs for NNTP newsgroup(s).