All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alex,Shi" <alex.shi@intel.com>
To: Corrado Zoccolo <czoccolo@gmail.com>, Jan Kara <jack@suse.cz>,
	"tytso@mit.edu" <tytso@mit.edu>
Cc: "vgoyal@redhat.com" <vgoyal@redhat.com>,
	"jaxboe@fusionio.com" <jaxboe@fusionio.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Li, Shaohua" <shaohua.li@intel.com>,
	"Chen, Tim C" <tim.c.chen@intel.com>
Subject: Re: [performance bug] kernel building regression on 64 LCPUs machine
Date: Fri, 21 Jan 2011 15:52:28 +0800	[thread overview]
Message-ID: <1295596348.32373.18.camel@debian> (raw)
In-Reply-To: <1295596057.32373.16.camel@debian>

Sorry for forgetting Jan and tytso. added again. 

On Fri, 2011-01-21 at 15:47 +0800, Alex,Shi wrote:
> On Fri, 2011-01-21 at 15:23 +0800, Corrado Zoccolo wrote:
> > On Wed, Jan 19, 2011 at 2:55 AM, Alex,Shi <alex.shi@intel.com> wrote:
> > > Shaohua and I tested kernel building performance on latest kernel. and
> > > found it is drop about 15% on our 64 LCPUs NHM-EX machine on ext4 file
> > > system. We find this performance dropping is due to commit
> > > 749ef9f8423054e326f. If we revert this patch or just change the
> > > WRITE_SYNC back to WRITE in jbd2/commit.c file. the performance can be
> > > recovered.
> > >
> > > iostat report show with the commit, read request merge number increased
> > > and write request merge dropped. The total request size increased and
> > > queue length dropped. So we tested another patch: only change WRITE_SYNC
> > > to WRITE_SYNC_PLUG in jbd2/commit.c, but nothing effected.
> > >
> > > we didn't test deadline IO mode, just test cfq. seems insert write
> > > request into sync queue effect much read performance, but we don't know
> > > details. What's your comments of this?
> > >
> > > iostat of .37 kernel:
> > > rrqm/s   wrqm/s r/s     w/s     rMB/s  wMB/s avgrq-sz avgqu-sz   await  svctm  %util
> > > 22.5772 96.46 92.3742 14.747  1.0048  0.439474 34.8557 0.18078 3.8076 0.30447 2.94302
> > > iostat of commit reverted .37:
> > > 26.6223 80.21 107.875 6.03538 1.51415 0 41.3275 0.153385 3.80569 0.377231 3.22323
> > 
> > From these numbers, it seems to me that with the patch reverted, the
> > write bandwidth is really low, and probably you are keeping most
> > written files in the buffer cache during the whole compile, while the
> > non-reverted kernel is making progress in writing out the files. So
> > the 'improved' read bandwidth is due to unfairness w.r.t. writes.
> > Does the result change if you add a final sync and time that as well,
> > in order to see the full time to make it on disk?
> 
> Agree with your guess, but kbuild is such kind of benchmark, we can not
> change its behavior. :( 
> 
> 
> > 
> > I think that in a more extreme test where you end up filling all the
> > buffer cache with written data, you will see much longer stalls with
> > the revert than without.
> 
> Have to do this? and if so, it is not kbuild. :) 
> 
> BTW, the Jan's patch has a little improvement on kbuild. In many time
> testing, it seems about 3% improving. 
> 
> The average iostat output of Jan's patch: 
>  rrqm/s   wrqm/s r/s     w/s     rMB/s  wMB/s avgrq-sz avgqu-sz   await  svctm  %util
> 23.419726 87.450685 96.164521 6.748493 1.046438 0.370137 45.182192 0.200685 6.848767 0.394110 3.072192
> 
> > 
> > Thanks,
> > Corrado
> > 
> > >
> > > vmstat report show, read bandwidth dropping:
> > > vmstat of .37:
> > >  r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa st
> > > 3.4 52.6 0.0 64303937.0 16466.7 121544.5 0.0 0.0 2102.7 1914.6 7414.1 3185.7 2.0 1.0 80.3 16.7 0.0
> > > vmstat of revert all from .37
> > > 2.2 35.8 0.0 64306767.4 17265.6 126101.2 0.0 0.0 2415.8 1619.1 8532.2 3556.2 2.5 1.1 83.0 13.3 0.0
> > >
> > > Regards
> > > Alex
> > >
> > > ===
> > > diff --git a/fs/jbd/commit.c b/fs/jbd/commit.c
> > > index 34a4861..27ac2f3 100644
> > > --- a/fs/jbd/commit.c
> > > +++ b/fs/jbd/commit.c
> > > @@ -294,7 +294,7 @@ void journal_commit_transaction(journal_t *journal)
> > >        int first_tag = 0;
> > >        int tag_flag;
> > >        int i;
> > > -       int write_op = WRITE_SYNC;
> > > +       int write_op = WRITE;
> > >
> > >        /*
> > >         * First job: lock down the current transaction and wait for
> > > diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c
> > > index f3ad159..69ff08e 100644
> > > --- a/fs/jbd2/commit.c
> > > +++ b/fs/jbd2/commit.c
> > > @@ -329,7 +329,7 @@ void jbd2_journal_commit_transaction(journal_t *journal)
> > >        int tag_bytes = journal_tag_bytes(journal);
> > >        struct buffer_head *cbh = NULL; /* For transactional checksums */
> > >        __u32 crc32_sum = ~0;
> > > -       int write_op = WRITE_SYNC;
> > > +       int write_op = WRITE;
> > >
> > >        /*
> > >         * First job: lock down the current transaction and wait for
> > >
> > >
> > >
> > 
> > 
> > 
> 



  reply	other threads:[~2011-01-21  7:53 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-19  1:55 [performance bug] kernel building regression on 64 LCPUs machine Alex,Shi
2011-01-19  2:03 ` Shaohua Li
2011-01-19 12:56   ` Jan Kara
2011-01-20  7:52     ` Alex,Shi
2011-01-20 15:16   ` Vivek Goyal
2011-01-21  7:17     ` Shaohua Li
2011-01-26  8:15     ` Shaohua Li
2011-02-12  9:21       ` Alex,Shi
2011-02-12 18:25         ` Corrado Zoccolo
2011-02-14  2:25           ` Alex,Shi
2011-02-15  1:10             ` Shaohua Li
2011-02-21 16:49               ` Jan Kara
2011-02-23  8:24                 ` Alex,Shi
2011-02-24 12:13                   ` Jan Kara
2011-02-25  0:44                     ` Alex Shi
2011-02-26 14:45                     ` Corrado Zoccolo
2011-03-01 19:56                       ` Jeff Moyer
2011-03-02  9:42                         ` Jan Kara
2011-03-02 16:13                           ` Jeff Moyer
2011-03-02 21:17                             ` Jan Kara
2011-03-02 21:20                               ` Jeff Moyer
2011-03-03  1:14                               ` Jeff Moyer
2011-03-04 15:32                                 ` Jan Kara
2011-03-04 15:40                                   ` Jeff Moyer
2011-03-04 15:50                                   ` Jeff Moyer
2011-03-04 18:27                                     ` Jeff Moyer
2011-03-22  7:38                                       ` Alex,Shi
2011-03-22 16:14                                         ` Jan Kara
2011-03-22 17:46                                           ` Jeff Moyer
2011-03-24  6:45                                             ` Alex,Shi
2011-03-28 19:48                                             ` Jan Kara
2011-01-19 14:32 ` Ted Ts'o
2011-01-20  2:12   ` Shaohua Li
2011-01-21  7:23 ` Corrado Zoccolo
2011-01-21  7:47   ` Alex,Shi
2011-01-21  7:52     ` Alex,Shi [this message]
2011-01-21  8:13       ` Corrado Zoccolo
2011-01-21  8:20   ` Shaohua Li

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=1295596348.32373.18.camel@debian \
    --to=alex.shi@intel.com \
    --cc=czoccolo@gmail.com \
    --cc=jack@suse.cz \
    --cc=jaxboe@fusionio.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=shaohua.li@intel.com \
    --cc=tim.c.chen@intel.com \
    --cc=tytso@mit.edu \
    --cc=vgoyal@redhat.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.