From: Waiman Long <waiman.long@hpe.com>
To: Tejun Heo <tj@kernel.org>
Cc: Theodore Ts'o <tytso@mit.edu>,
Andreas Dilger <adilger.kernel@dilger.ca>,
Christoph Lameter <cl@linux.com>, <linux-ext4@vger.kernel.org>,
<linux-kernel@vger.kernel.org>,
Scott J Norton <scott.norton@hpe.com>,
Douglas Hatch <doug.hatch@hpe.com>,
Toshimitsu Kani <toshi.kani@hpe.com>
Subject: Re: [PATCH 2/3] percpu_stats: Simple per-cpu statistics count helper functions
Date: Thu, 7 Apr 2016 14:52:33 -0400 [thread overview]
Message-ID: <5706AC71.3080801@hpe.com> (raw)
In-Reply-To: <20160407160623.GF7822@mtj.duckdns.org>
On 04/07/2016 12:06 PM, Tejun Heo wrote:
> Hello, Waiman.
>
> On Thu, Apr 07, 2016 at 11:58:13AM -0400, Waiman Long wrote:
>> We can certainly make it watertight. However, that will certainly require
>> adding performance overhead in the percpu stats update fast path which I am
>> not willing to pay.
> There are multiple options depending on the specific balance you want
> to hit. Reset can be made very heavy (involving RCU sync operation)
> to make hot path overhead minimal, local locking or atomic ops can
> also be used which while more expensive than this_cpu_*() ops still
> avoids cacheline bouncing.
>
>> The purpose of this stat counters reset functionality is to allow developers
>> to reset the stat counters, run certain workload and see how things are
>> going in the kernel when the workload completes assuming that those stat
>> counters are exposed via sysfs, debugfs, etc. The developers can certainly
>> check the stat counters after the reset to make sure that they are properly
>> reset. So I don't think we need an airtight way of doing it. If you have
>> scenarios in your mind that require airtight reset of the stat counters,
>> please let me know and I will see what I can do about it.
> No matter what, don't create something which can yield a completely
> surprising result once in a blue moon. You might think it's okay
> because the likelihood is low but that just means that the resulting
> malfunctions will be that much more obscure and difficult to
> reproduce.
>
> Thanks.
>
As long as atomic reset is an optional feature that caller can choose at
init time, I am OK to provide this functionality. I just don't want it
to be the default because of the performance overhead.
Cheers,
Longman
next prev parent reply other threads:[~2016-04-07 19:07 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-02 3:09 [PATCH 0/3] ext4: Improve parallel I/O performance on NVDIMM Waiman Long
2016-04-02 3:09 ` [PATCH 1/3] ext4: Pass in DIO_SKIP_DIO_COUNT flag if inode_dio_begin() called Waiman Long
2016-04-02 3:09 ` [PATCH 2/3] percpu_stats: Simple per-cpu statistics count helper functions Waiman Long
2016-04-04 7:36 ` Nikolay Borisov
2016-04-04 17:11 ` Waiman Long
2016-04-04 19:09 ` Christoph Lameter
2016-04-06 21:53 ` Waiman Long
2016-04-04 16:02 ` Tejun Heo
2016-04-06 19:52 ` Waiman Long
2016-04-06 21:51 ` Waiman Long
2016-04-06 22:54 ` Tejun Heo
2016-04-07 15:58 ` Waiman Long
2016-04-07 16:06 ` Tejun Heo
2016-04-07 18:52 ` Waiman Long [this message]
2016-04-07 18:58 ` Tejun Heo
2016-04-07 20:37 ` Waiman Long
2016-04-07 20:41 ` Tejun Heo
2016-04-07 21:38 ` Waiman Long
2016-04-02 3:09 ` [PATCH 3/3] ext4: Make cache hits/misses per-cpu counts Waiman Long
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=5706AC71.3080801@hpe.com \
--to=waiman.long@hpe.com \
--cc=adilger.kernel@dilger.ca \
--cc=cl@linux.com \
--cc=doug.hatch@hpe.com \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=scott.norton@hpe.com \
--cc=tj@kernel.org \
--cc=toshi.kani@hpe.com \
--cc=tytso@mit.edu \
/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.