linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tim Chen <tim.c.chen@linux.intel.com>
To: Al Viro <viro@zeniv.linux.org.uk>
Cc: suruchi <suruchi.a.kadu@intel.com>, ak <ak@linux.intel.com>,
	Dave Hansen <dave.hansen@intel.com>,
	Matthew Wilcox <willy@linux.intel.com>,
	"hubert.nueckel" <hubert.nueckel@intel.com>,
	beth.marsh-prime@intel.com, "doug.nelson" <doug.nelson@intel.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	linux-fsdevel <linux-fsdevel@vger.kernel.org>
Subject: [Regression 3.16-rc kernel] -55% reduction in throughput for OLTP benchmark
Date: Mon, 28 Jul 2014 14:51:39 -0700	[thread overview]
Message-ID: <1406584299.2970.924.camel@schen9-DESK> (raw)

Al,

We saw a large regression (-55%) in a standard OLTP benchmark
between 3.15 kernel and 3.16-rc4 kernel.

One issue was caused by the changes in async direct IO in the 
direct IO patch series between commit f6c0a192 and 62a8067a 
for the 3.16-rc kernel.  The kernel before this series at 
commit 38583f09 has no such regression.

After some investigations and instrumentation, we saw that the
problem was caused by a lot of io_wait issued from 
do_blockdev_direct_IO for async direct IO writes, which
did not happen for 3.15 kernel.  The benchmark
used to run at 97% cpu utilization now has only
35% cpu utilization with plenty of idle time.

At the end of do_blockdev_direct_IO, 

        if (dio->is_async && retval == 0 && dio->result &&
            ((rw == READ) || (dio->result == sdio.size)))
                retval = -EIOCBQUEUED;

        if (retval != -EIOCBQUEUED)
                dio_await_completion(dio);

we saw for async writes, the check
for (dio->result == sdio.size) failed. The retval was not
set to -EIOCBQUEUED, causing dio_await_completion to be issued
and hence the io_waits.

It is possible that the problem was introduced when dio->result
computation was moved into do_direct_IO in commit 3320c60b.
However, we cannot compile and test this commit separately as 
it is dependent on some later patches in the direct IO patch series
so we have to test the patch series as a whole.

This is quite a large regression for us and we hope that
it can be fixed before 3.16 kernel is released.

Thanks.

Tim


             reply	other threads:[~2014-07-28 21:52 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-28 21:51 Tim Chen [this message]
2014-07-29 14:19 ` [Regression 3.16-rc kernel] -55% reduction in throughput for OLTP benchmark Christoph Hellwig
2014-07-29 16:35   ` Tim Chen
2014-07-29 16:49     ` Christoph Hellwig
2014-07-29 17:41       ` Tim Chen
2014-07-29 23:57       ` Tim Chen
2014-07-30  0:12         ` Christoph Hellwig
2014-07-31 16:13           ` Tim Chen
2014-07-31 17:07             ` Linus Torvalds
2014-07-31 17:10               ` Christoph Hellwig
2014-07-31 17:22                 ` Linus Torvalds
2014-08-01  6:45           ` Al Viro

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=1406584299.2970.924.camel@schen9-DESK \
    --to=tim.c.chen@linux.intel.com \
    --cc=ak@linux.intel.com \
    --cc=beth.marsh-prime@intel.com \
    --cc=dave.hansen@intel.com \
    --cc=doug.nelson@intel.com \
    --cc=hubert.nueckel@intel.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=suruchi.a.kadu@intel.com \
    --cc=viro@zeniv.linux.org.uk \
    --cc=willy@linux.intel.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).