From: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
To: Christoph Lameter <cl@linux-foundation.org>
Cc: Tejun Heo <tj@kernel.org>, linux-kernel@vger.kernel.org
Subject: Re: [RFC local_t removal V1 0/4] Remove local_t
Date: Tue, 5 Jan 2010 17:45:16 -0500 [thread overview]
Message-ID: <20100105224516.GA32584@Krystal> (raw)
In-Reply-To: <alpine.DEB.2.00.1001051629550.9108@router.home>
* Christoph Lameter (cl@linux-foundation.org) wrote:
> On Tue, 5 Jan 2010, Mathieu Desnoyers wrote:
>
> > Yes, removing the local_t type could make sense. However, local_t maps
> > to a volatile long, not just "long". Secondly, I am concerned about the
> > fact that the patch you propose:
>
> Volatile is discouraged as far as I can tell.
If you want to ensure that a simple variable assignment or read
(local_set, local_read) are not performed piecewise by the compiler
which can cause odd effects when shared with interrupt handlers, this
will however be necessary.
>
> > - does not create the primitives I use in lttng
> > - only deals with x8
>
> As I said its an RFC. This provides all the functionality you need
> through. The rest is sugar coating.
OK
>
> > In lttng (which is out of tree, but widely used), I need the equivalent
> > of:
> >
> > local_read
> > local_set
> > local_add
> > local_cmpxchg
> > local_add_return
> > local_inc
>
> Please read the patch! This is all provided. add_local_return in the RFC
> provides what is needed to replace local_add, local_inc. We can add these
> explicitly.
>
> local_cmpxchg replacement is already in there in the form of
> cmpxchg_local().
>
> > The approach of just doing the x86 implementation and leaving all the
> > other architectures "for later" with a slow/non atomic generic fallback
> > is, imho, a no-go, given that some people (myself, actually) already
> > took the time to go through all the kernel architectures to create the
> > optimized local.h headers. Basically, you are destroying all that work,
> > asking for it to be done all over again.
>
> AS I said this is an RFC. I can easily generate all these things from the
> existing local.hs for the architectures.
>
> > I therefore argue that we should keep local.h as-is as long as the
> > replacement lacks the wide architecture support and primitive variety
> > found in local.h.
>
> Cool down and please review the patch.
OK :)
Mathieu
>
>
--
Mathieu Desnoyers
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68
next prev parent reply other threads:[~2010-01-05 22:45 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-05 22:04 [RFC local_t removal V1 0/4] Remove local_t Christoph Lameter
2010-01-05 22:04 ` [RFC local_t removal V1 1/4] Add add_local() and add_local_return() Christoph Lameter
2010-01-05 22:17 ` Mike Frysinger
2010-01-05 22:29 ` Christoph Lameter
2010-01-06 19:23 ` Mike Frysinger
2010-01-07 17:03 ` Christoph Lameter
2010-01-05 22:49 ` Mathieu Desnoyers
2010-01-07 13:45 ` Arnd Bergmann
2010-01-07 13:57 ` Mathieu Desnoyers
2010-01-07 14:22 ` Arnd Bergmann
2010-01-07 17:07 ` Christoph Lameter
2010-01-05 22:04 ` [RFC local_t removal V1 2/4] Replace local_t use in trace subsystem Christoph Lameter
2010-01-05 22:57 ` Mathieu Desnoyers
2010-01-07 17:15 ` Christoph Lameter
2010-01-14 2:56 ` Steven Rostedt
2010-01-14 14:49 ` Christoph Lameter
2010-01-05 22:04 ` [RFC local_t removal V1 3/4] Optimized add_local() Christoph Lameter
2010-01-05 22:59 ` Mathieu Desnoyers
2010-01-07 17:16 ` Christoph Lameter
2010-01-05 22:04 ` [RFC local_t removal V1 4/4] Remove local_t support Christoph Lameter
2010-01-05 22:23 ` [RFC local_t removal V1 0/4] Remove local_t Mathieu Desnoyers
2010-01-05 22:34 ` Christoph Lameter
2010-01-05 22:45 ` Mathieu Desnoyers [this message]
2010-01-07 17:05 ` Christoph Lameter
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=20100105224516.GA32584@Krystal \
--to=mathieu.desnoyers@polymtl.ca \
--cc=cl@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tj@kernel.org \
/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).