linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dipankar Sarma <dipankar@in.ibm.com>
To: William Lee Irwin III <wli@holomorphy.com>,
	Zwane Mwaikambo <zwane@linuxpower.ca>,
	Andrew Morton <akpm@digeo.com>,
	lkml <linux-kernel@vger.kernel.org>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>
Subject: Re: 2.5.38-mm3
Date: Fri, 27 Sep 2002 15:28:34 +0530	[thread overview]
Message-ID: <20020927152833.D25021@in.ibm.com> (raw)
In-Reply-To: <20020927092020.GS3530@holomorphy.com>; from wli@holomorphy.com on Fri, Sep 27, 2002 at 02:20:20AM -0700

On Fri, Sep 27, 2002 at 02:20:20AM -0700, William Lee Irwin III wrote:
> On Fri, Sep 27, 2002 at 01:57:43PM +0530, Dipankar Sarma wrote:
> > What application were you all running ?
> > Thanks
> 
> Basically, the workload on my "desktop" system consists of numerous ssh
> sessions in and out of the machine, half a dozen IRC clients, xmms,
> Mozilla, and X overhead.

Ok, from a relatively idle system (4CPU) running SMP kernel -

    18 fget                                       0.2250
0           0.00        c013d460:       push   %ebx
0           0.00        c013d461:       mov    $0xffffe000,%edx
0           0.00        c013d466:       mov    %eax,%ecx
0           0.00        c013d468:       and    %esp,%edx
0           0.00        c013d46a:       mov    (%edx),%eax
1           5.56        c013d46c:       mov    0x674(%eax),%ebx
1           5.56        c013d472:       lea    0x4(%ebx),%eax
0           0.00        c013d475:       lock subl $0x1,(%eax)
3          16.67        c013d479:       js     c013d61b <.text.lock.file_table+0x30>
0           0.00        c013d47f:       mov    (%edx),%eax
1           5.56        c013d481:       mov    0x674(%eax),%edx
0           0.00        c013d487:       xor    %eax,%eax
0           0.00        c013d489:       cmp    0x8(%edx),%ecx
0           0.00        c013d48c:       jae    c013d494 <fget+0x34>
0           0.00        c013d48e:       mov    0x14(%edx),%eax
0           0.00        c013d491:       mov    (%eax,%ecx,4),%eax
0           0.00        c013d494:       test   %eax,%eax
0           0.00        c013d496:       je     c013d49c <fget+0x3c>
0           0.00        c013d498:       lock incl 0x14(%eax)
0           0.00        c013d49c:       lock incl 0x4(%ebx)
5          27.78        c013d4a0:       pop    %ebx
0           0.00        c013d4a1:       ret
7          38.89        c013d4a2:       lea    0x0(%esi,1),%esi

I tried an SMP kernel on 1 CPU -

    15 fget                                       0.1875
0           0.00        c013d460:       push   %ebx
2          13.33        c013d461:       mov    $0xffffe000,%edx
0           0.00        c013d466:       mov    %eax,%ecx
0           0.00        c013d468:       and    %esp,%edx
0           0.00        c013d46a:       mov    (%edx),%eax
0           0.00        c013d46c:       mov    0x674(%eax),%ebx
0           0.00        c013d472:       lea    0x4(%ebx),%eax
0           0.00        c013d475:       lock subl $0x1,(%eax)
3          20.00        c013d479:       js     c013d61b <.text.lock.file_table+0x30>
0           0.00        c013d47f:       mov    (%edx),%eax
0           0.00        c013d481:       mov    0x674(%eax),%edx
0           0.00        c013d487:       xor    %eax,%eax
0           0.00        c013d489:       cmp    0x8(%edx),%ecx
0           0.00        c013d48c:       jae    c013d494 <fget+0x34>
0           0.00        c013d48e:       mov    0x14(%edx),%eax
0           0.00        c013d491:       mov    (%eax,%ecx,4),%eax
0           0.00        c013d494:       test   %eax,%eax
0           0.00        c013d496:       je     c013d49c <fget+0x3c>
0           0.00        c013d498:       lock incl 0x14(%eax)
0           0.00        c013d49c:       lock incl 0x4(%ebx)
4          26.67        c013d4a0:       pop    %ebx
0           0.00        c013d4a1:       ret    
6          40.00        c013d4a2:       lea    0x0(%esi,1),%esi

The counts are off by one.

With a UP kernel, I see that fget() cost is negligible.
So it is most likely the atomic operations for rwlock acquisition/release
in fget() that is adding to its cost. Unless of course my sampling
is too less.

Please try running the files_struct_rcu patch where fget() is lockfree
and let me know what you see.

Thanks
-- 
Dipankar Sarma  <dipankar@in.ibm.com> http://lse.sourceforge.net
Linux Technology Center, IBM Software Lab, Bangalore, India.

  reply	other threads:[~2002-09-27  9:48 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-26  7:57 2.5.38-mm3 Andrew Morton
2002-09-26 12:24 ` 2.5.38-mm3 Dipankar Sarma
2002-09-26 12:29   ` 2.5.38-mm3 William Lee Irwin III
2002-09-26 12:40     ` 2.5.38-mm3 Dipankar Sarma
2002-09-26 12:42       ` 2.5.38-mm3 William Lee Irwin III
2002-09-26 13:05         ` 2.5.38-mm3 Dipankar Sarma
2002-09-26 13:17           ` 2.5.38-mm3 William Lee Irwin III
2002-09-26 13:29         ` 2.5.38-mm3 Zwane Mwaikambo
2002-09-26 13:39           ` 2.5.38-mm3 William Lee Irwin III
2002-09-26 13:46             ` 2.5.38-mm3 Zwane Mwaikambo
2002-09-27  8:27             ` 2.5.38-mm3 Dipankar Sarma
2002-09-27  9:20               ` 2.5.38-mm3 William Lee Irwin III
2002-09-27  9:58                 ` Dipankar Sarma [this message]
2002-09-27 15:04                   ` 2.5.38-mm3 Martin J. Bligh
2002-09-27 17:14                     ` 2.5.38-mm3 Dipankar Sarma
2002-09-27 22:54                       ` 2.5.38-mm3 William Lee Irwin III
2002-09-28  5:41                         ` 2.5.38-mm3 Dipankar Sarma
2002-09-28  4:35                   ` 2.5.38-mm3 Zwane Mwaikambo
2002-09-28  4:36                     ` 2.5.38-mm3 William Lee Irwin III
2002-09-28  4:54                       ` 2.5.38-mm3 Zwane Mwaikambo
2002-09-28  5:29                         ` 2.5.38-mm3 Dipankar Sarma
2002-09-28  4:30                 ` 2.5.38-mm3 Zwane Mwaikambo

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=20020927152833.D25021@in.ibm.com \
    --to=dipankar@in.ibm.com \
    --cc=akpm@digeo.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=wli@holomorphy.com \
    --cc=zwane@linuxpower.ca \
    /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).