From: Nick Piggin <nickpiggin@yahoo.com.au>
To: Andrew Morton <akpm@osdl.org>
Cc: tim.c.chen@linux.intel.com, herbert@gondor.apana.org.au,
linux-kernel@vger.kernel.org, leonid.i.ananiev@intel.com
Subject: Re: [PATCH] Fix WARN_ON / WARN_ON_ONCE regression
Date: Wed, 04 Oct 2006 11:47:05 +1000 [thread overview]
Message-ID: <45231299.1000601@yahoo.com.au> (raw)
In-Reply-To: <20061003181452.778291fb.akpm@osdl.org>
Andrew Morton wrote:
> On Tue, 03 Oct 2006 17:09:29 -0700
> Tim Chen <tim.c.chen@linux.intel.com> wrote:
>
>
>>On Tue, 2006-10-03 at 17:07 -0700, Andrew Morton wrote:
>>
>>
>>>Perhaps the `static int __warn_once' is getting put in the same cacheline
>>>as some frequently-modified thing. Perhaps try marking that as __read_mostly?
>>>
>>
>>I've tried marking static int __warn_once as __read_mostly. However, it
>>did not help with reducing the cache miss :(
>>
>>So I would suggest reversing the "Let WARN_ON/WARN_ON_ONCE return the
>>condition" patch. It has just been added 3 days ago so reversing it
>>should not be a problem.
>>
>
>
> Not yet, please. This is presently a mystery, and we need to work out
> what's going on.
Still, it seems kind of odd to add this IMO. Especially the WARN_ON_ONCE
makes the if statement less readable.
if (WARN_ON_ONCE(blah)) {
}
What does that mean? Without looking at the implementation, that says
the condition is true at most once, when the warning is printed.
What's wrong with adding WARN and WARN_ONCE, and eating the single extra
line? You're always telling people to do that with assignments (which I
agree with, but are _more_ readable than this WARN_ON_ONCE thing).
--
SUSE Labs, Novell Inc.
Send instant messages to your online friends http://au.messenger.yahoo.com
next prev parent reply other threads:[~2006-10-04 1:46 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-03 23:04 [PATCH] Fix WARN_ON / WARN_ON_ONCE regression Tim Chen
2006-10-03 23:19 ` Tim Chen
2006-10-04 0:06 ` Jeremy Fitzhardinge
2006-10-03 23:47 ` Tim Chen
2006-10-04 4:39 ` Jeremy Fitzhardinge
2006-10-04 13:21 ` Tim Chen
2006-10-04 16:30 ` Andrew Morton
2006-10-04 16:22 ` Tim Chen
2006-10-04 17:34 ` Andrew Morton
2006-10-04 20:43 ` Tim Chen
2006-10-10 1:09 ` Tim Chen
2006-10-10 13:04 ` Steven Rostedt
2006-10-10 15:41 ` Tim Chen
2006-10-10 20:03 ` Jeremy Fitzhardinge
2006-10-04 0:07 ` Andrew Morton
2006-10-03 23:42 ` Tim Chen
2006-10-04 0:09 ` Tim Chen
2006-10-04 1:14 ` Andrew Morton
2006-10-04 1:47 ` Nick Piggin [this message]
2006-10-04 3:24 ` Andrew James Wade
2006-10-04 3:32 ` Andrew Morton
2006-10-04 16:47 ` Andrew James Wade
2006-10-04 22:06 ` Andrew Morton
2006-10-05 8:13 ` Andrew James Wade
2006-10-05 8:36 ` Andrew Morton
2006-10-05 21:31 ` Andrew James Wade
2006-10-05 21:01 ` Tim Chen
-- strict thread matches above, loose matches on Subject: below --
2006-10-04 16:57 Ananiev, Leonid I
2006-10-04 17:28 ` Andrew Morton
2006-10-08 0:28 ` Steven Rostedt
2006-10-08 0:39 ` Jeremy Fitzhardinge
2006-10-04 21:55 Ananiev, Leonid I
2006-10-05 21:37 ` Andrew Morton
2006-10-05 21:43 ` Jeremy Fitzhardinge
2006-10-05 21:52 ` Andrew Morton
2006-10-05 22:02 ` Herbert Xu
2006-10-05 22:40 ` Jeremy Fitzhardinge
2006-10-05 21:51 ` Tim Chen
2006-10-06 16:11 ` Andrew James Wade
2006-10-06 4:06 Ananiev, Leonid I
2006-10-10 21:05 Ananiev, Leonid I
2006-10-10 21:17 ` Steven Rostedt
2006-10-10 21:41 ` Roland Dreier
2006-10-10 22:59 ` Jeremy Fitzhardinge
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=45231299.1000601@yahoo.com.au \
--to=nickpiggin@yahoo.com.au \
--cc=akpm@osdl.org \
--cc=herbert@gondor.apana.org.au \
--cc=leonid.i.ananiev@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tim.c.chen@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 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.