From: Nathan Zimmer <nzimmer@sgi.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: <linux-kernel@vger.kernel.org>, <linux-fsdevel@vger.kernel.org>,
Alexander Viro <viro@zeniv.linux.org.uk>,
David Woodhouse <dwmw2@infradead.org>,
Alexey Dobriyan <adobriyan@gmail.com>,
<paulmck@linux.vnet.ibm.com>
Subject: Re: [PATCH] procfs: Improve Scaling in proc
Date: Thu, 18 Oct 2012 14:54:03 -0500 [thread overview]
Message-ID: <50805E5B.8090209@sgi.com> (raw)
In-Reply-To: <1350546398.26103.1133.camel@edumazet-glaptop>
On 10/18/2012 02:46 AM, Eric Dumazet wrote:
> On Wed, 2012-10-17 at 15:25 -0500, Nathan Zimmer wrote:
>> I am currently tracking a hotlock reported by a customer on a large, 512 cores,
>> system, I am currently running 3.7.0 rc1 but the issue looks like it has been
>> this way for a very long time.
>> The offending lock is proc_dir_entry->pde_unload_lock.
>>
>> This patch converts the replaces the lock with the rcu. It is a refresh of what
>> was orignally suggested by Eric Dumazet. I refreshed it to the 3.7.
>>
>> Supporting numbers, lower is better, they are from the test I posted earlier.
>> cpuinfo baseline Rcu
>> tasks read-sec read-sec
>> 1 0.0141 0.0141
>> 2 0.0140 0.0142
>> 4 0.0140 0.0141
>> 8 0.0145 0.0140
>> 16 0.0553 0.0168
>> 32 0.1688 0.0549
>> 64 0.5017 0.1690
>> 128 1.7005 0.5038
>> 256 5.2513 2.0804
>> 512 8.0529 3.0162
>>
>>
>> Cc: Eric Dumazet <eric.dumazet@gmail.com>
>> Cc: Alexander Viro <viro@zeniv.linux.org.uk>
>> Cc: David Woodhouse <dwmw2@infradead.org>
>> Cc: Alexey Dobriyan <adobriyan@gmail.com>
>> Signed-off-by: Nathan Zimmer <nzimmer@sgi.com>
>
> Hmm, this patch had several issues and I had no time yet to work on a
> new version. I probably wont have time in a near future.
>
> Paul sent me some comments about it, I hope he doesnt mind I copy them
> here, if you want to polish the patch.
>
> Thanks !
I'll try to polish this up and resend it.
And any comments are most welcome.
> On Wed, 2012-10-03 at 10:56 -0700, Paul E. McKenney wrote:
>> Finally getting back to this... :-/
>>
>> Why not set the initial value of the reference counter to 1
>> (rather than zero), continue acquiring with atomic_inc(), but
>> use atomic_dec_and_test() to decrement? Put a completion in
>> the data structure, so if the atomic_dec_and_test() indicates that
>> the counter is now zero, do a complete().
>>
>> Then to free the object, remove it from the data structure, do a
>> synchronize_rcu(), do an atomic_dec_and_test() to remove the initial
>> value, again doing a complete() if the counter is now zero. The do
>> a wait_for_completion().
>>
>> This would get rid of the polling loop.
>>
>> So, what am I missing here? ;-)
>>
>> Thanx, Paul
>>
prev parent reply other threads:[~2012-10-18 19:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-17 20:25 [PATCH] procfs: Improve Scaling in proc Nathan Zimmer
2012-10-18 7:46 ` Eric Dumazet
2012-10-18 19:54 ` Nathan Zimmer [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=50805E5B.8090209@sgi.com \
--to=nzimmer@sgi.com \
--cc=adobriyan@gmail.com \
--cc=dwmw2@infradead.org \
--cc=eric.dumazet@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulmck@linux.vnet.ibm.com \
--cc=viro@zeniv.linux.org.uk \
/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.