linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Vlastimil Babka <vbabka@suse.cz>
To: WANG Chao <chaowang@redhat.com>,
	Andrew Morton <akpm@linux-foundation.org>
Cc: Davidlohr Bueso <dave@stgolabs.net>,
	Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Michel Lespinasse <walken@google.com>,
	Rik van Riel <riel@redhat.com>, Mel Gorman <mgorman@suse.de>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm, vmacache: Add kconfig VMACACHE_SHIFT
Date: Thu, 22 Jan 2015 16:45:03 +0100	[thread overview]
Message-ID: <54C11AFF.5040505@suse.cz> (raw)
In-Reply-To: <1421908189-18938-1-git-send-email-chaowang@redhat.com>

On 01/22/2015 07:29 AM, WANG Chao wrote:
> Add a new kconfig option VMACACHE_SHIFT (as a power of 2) to specify the
> number of slots vma cache has for each thread. Range is chosen 0-4 (1-16
> slots) to consider both overhead and performance penalty. Default is 2

One could say that overhead and performance penalty is the same thing. 
Please elaborate?

Also, got any performance numbers to share for workloads benefiting from 
more/less than the default?

> (4 slots) as it originally is, which provides good enough balance.
>
> Signed-off-by: WANG Chao <chaowang@redhat.com>
> ---
>   include/linux/sched.h | 2 +-
>   mm/Kconfig            | 7 +++++++
>   2 files changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/include/linux/sched.h b/include/linux/sched.h
> index 8db31ef..56fd96d 100644
> --- a/include/linux/sched.h
> +++ b/include/linux/sched.h
> @@ -134,7 +134,7 @@ struct perf_event_context;
>   struct blk_plug;
>   struct filename;
>
> -#define VMACACHE_BITS 2
> +#define VMACACHE_BITS CONFIG_VMACACHE_SHIFT
>   #define VMACACHE_SIZE (1U << VMACACHE_BITS)
>   #define VMACACHE_MASK (VMACACHE_SIZE - 1)
>
> diff --git a/mm/Kconfig b/mm/Kconfig
> index 1d1ae6b..7b82a52 100644
> --- a/mm/Kconfig
> +++ b/mm/Kconfig
> @@ -618,3 +618,10 @@ config MAX_STACK_SIZE_MB
>   	  changed to a smaller value in which case that is used.
>
>   	  A sane initial value is 80 MB.
> +
> +config VMACACHE_SHIFT
> +	int "Number of slots in per-thread VMA cache (as a power of 2)"
> +	range 0 4
> +	default 2
> +	help
> +	  This is the number of slots VMA cache has for each thread.

As a user, I wouldn't find this informative enough to make the decision.


--
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>

      parent reply	other threads:[~2015-01-22 15:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-22  6:29 [PATCH] mm, vmacache: Add kconfig VMACACHE_SHIFT WANG Chao
2015-01-22  7:46 ` Davidlohr Bueso
2015-01-22  7:57   ` WANG Chao
2015-01-22 16:19     ` Davidlohr Bueso
2015-01-22 16:22       ` Rik van Riel
2015-01-23  5:14         ` WANG Chao
2015-01-24  1:02           ` Sasha Levin
2015-01-22 15:45 ` Vlastimil Babka [this message]

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=54C11AFF.5040505@suse.cz \
    --to=vbabka@suse.cz \
    --cc=akpm@linux-foundation.org \
    --cc=chaowang@redhat.com \
    --cc=dave@stgolabs.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=riel@redhat.com \
    --cc=walken@google.com \
    /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).