All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Jens Axboe <jens.axboe@oracle.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Ehrhardt Christian <ehrhardt@linux.vnet.ibm.com>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Martin Schwidefsky <schwidefsky@de.ibm.com>,
	Wu Fengguang <fengguang.wu@intel.com>
Subject: Re: [PATCH] mm: make VM_MAX_READAHEAD configurable
Date: Fri, 9 Oct 2009 14:31:24 -0700	[thread overview]
Message-ID: <20091009143124.1241a6bc.akpm@linux-foundation.org> (raw)
In-Reply-To: <20091009122952.GI9228@kernel.dk>

On Fri, 9 Oct 2009 14:29:52 +0200
Jens Axboe <jens.axboe@oracle.com> wrote:

> On Fri, Oct 09 2009, Peter Zijlstra wrote:
> > On Fri, 2009-10-09 at 13:19 +0200, Ehrhardt Christian wrote:
> > > From: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
> > > 
> > > On one hand the define VM_MAX_READAHEAD in include/linux/mm.h is just a default
> > > and can be configured per block device queue.
> > > On the other hand a lot of admins do not use it, therefore it is reasonable to
> > > set a wise default.
> > > 
> > > This path allows to configure the value via Kconfig mechanisms and therefore
> > > allow the assignment of different defaults dependent on other Kconfig symbols.
> > > 
> > > Using this, the patch increases the default max readahead for s390 improving
> > > sequential throughput in a lot of scenarios with almost no drawbacks (only
> > > theoretical workloads with a lot concurrent sequential read patterns on a very
> > > low memory system suffer due to page cache trashing as expected).
> > 
> > Why can't this be solved in userspace?
> > 
> > Also, can't we simply raise this number if appropriate? Wu did some
> > read-ahead trashing detection bits a long while back which should scale
> > the read-ahead window back when we're low on memory, not sure that ever
> > made it in, but that sounds like a better option than having different
> > magic numbers for each platform.
> 
> Agree, making this a config option (and even defaulting to a different
> number because of an arch setting) is crazy.

Given the (increasing) level of disparity between different kinds of
storage devices, having _any_ default is crazy.

Would be better to make some sort of vaguely informed guess at
runtime, based upon the characteristics of the device.


WARNING: multiple messages have this Message-ID (diff)
From: Andrew Morton <akpm@linux-foundation.org>
To: Jens Axboe <jens.axboe@oracle.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Ehrhardt Christian <ehrhardt@linux.vnet.ibm.com>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Martin Schwidefsky <schwidefsky@de.ibm.com>,
	Wu Fengguang <fengguang.wu@intel.com>
Subject: Re: [PATCH] mm: make VM_MAX_READAHEAD configurable
Date: Fri, 9 Oct 2009 14:31:24 -0700	[thread overview]
Message-ID: <20091009143124.1241a6bc.akpm@linux-foundation.org> (raw)
In-Reply-To: <20091009122952.GI9228@kernel.dk>

On Fri, 9 Oct 2009 14:29:52 +0200
Jens Axboe <jens.axboe@oracle.com> wrote:

> On Fri, Oct 09 2009, Peter Zijlstra wrote:
> > On Fri, 2009-10-09 at 13:19 +0200, Ehrhardt Christian wrote:
> > > From: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
> > > 
> > > On one hand the define VM_MAX_READAHEAD in include/linux/mm.h is just a default
> > > and can be configured per block device queue.
> > > On the other hand a lot of admins do not use it, therefore it is reasonable to
> > > set a wise default.
> > > 
> > > This path allows to configure the value via Kconfig mechanisms and therefore
> > > allow the assignment of different defaults dependent on other Kconfig symbols.
> > > 
> > > Using this, the patch increases the default max readahead for s390 improving
> > > sequential throughput in a lot of scenarios with almost no drawbacks (only
> > > theoretical workloads with a lot concurrent sequential read patterns on a very
> > > low memory system suffer due to page cache trashing as expected).
> > 
> > Why can't this be solved in userspace?
> > 
> > Also, can't we simply raise this number if appropriate? Wu did some
> > read-ahead trashing detection bits a long while back which should scale
> > the read-ahead window back when we're low on memory, not sure that ever
> > made it in, but that sounds like a better option than having different
> > magic numbers for each platform.
> 
> Agree, making this a config option (and even defaulting to a different
> number because of an arch setting) is crazy.

Given the (increasing) level of disparity between different kinds of
storage devices, having _any_ default is crazy.

Would be better to make some sort of vaguely informed guess at
runtime, based upon the characteristics of the device.

--
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:[~2009-10-09 21:32 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-09 11:19 [PATCH] mm: make VM_MAX_READAHEAD configurable Ehrhardt Christian
2009-10-09 11:19 ` Ehrhardt Christian
2009-10-09 12:20 ` Peter Zijlstra
2009-10-09 12:20   ` Peter Zijlstra
2009-10-09 12:29   ` Jens Axboe
2009-10-09 12:29     ` Jens Axboe
2009-10-09 13:49     ` Martin Schwidefsky
2009-10-09 13:49       ` Martin Schwidefsky
2009-10-09 13:58       ` Wu Fengguang
2009-10-09 13:58         ` Wu Fengguang
2009-10-11  1:10       ` Wu Fengguang
2009-10-11  1:10         ` Wu Fengguang
2009-10-12  5:53         ` Christian Ehrhardt
2009-10-12  5:53           ` Christian Ehrhardt
2009-10-12  6:23           ` Wu Fengguang
2009-10-12  6:23             ` Wu Fengguang
2009-10-12  9:29             ` Christian Ehrhardt
2009-10-12  9:29               ` Christian Ehrhardt
2009-10-12  9:39               ` Wu Fengguang
2009-10-12  9:39                 ` Wu Fengguang
2009-10-09 21:31     ` Andrew Morton [this message]
2009-10-09 21:31       ` Andrew Morton
2009-10-10 10:53       ` Jens Axboe
2009-10-10 10:53         ` Jens Axboe
2009-10-10 12:40         ` Wu Fengguang
2009-10-10 12:40           ` Wu Fengguang
2009-10-10 17:41           ` Andrew Morton
2009-10-10 17:41             ` Andrew Morton
2009-10-09 13:14   ` Wu Fengguang
2009-10-09 13:14     ` Wu Fengguang

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=20091009143124.1241a6bc.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=a.p.zijlstra@chello.nl \
    --cc=ehrhardt@linux.vnet.ibm.com \
    --cc=fengguang.wu@intel.com \
    --cc=jens.axboe@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=schwidefsky@de.ibm.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.