linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris Snook <csnook@redhat.com>
To: Linux Kernel <linux-kernel@vger.kernel.org>, linux-arch@vger.kernel.org
Subject: [RFP] atomic[64]_[read|set] asm implementations
Date: Wed, 15 Aug 2007 13:55:37 -0400	[thread overview]
Message-ID: <46C33E19.3050805@redhat.com> (raw)

In the fallout from the recent atomic_t volatility discussions, patches 
have been posted to moot the compiler correctness issues by implementing 
atomic[64]_[read|set] in inline assembly on powerpc, i386, and x86_64. 
While I personally don't consider such implementations to be critically 
necessary, they slightly reduce binary size and greatly reduce lkml 
controversy, so I like them.

I'm not an inline assembly expert, but I would welcome it if those who 
are would like to submit implementations of these functions for 
architectures they're intimately familiar with.  I'll pull them into the 
atomic_t patch set I've stumbled into shepherding, and hopefully we can 
commit something all at once that makes all architectures consistent, 
resists compiler bugs, and doesn't piss off too many people.

For architectures whose maintainers aren't worried and whose 
developers/users aren't bothered enough to submit an inline assembly 
patch, I'll just keep the inlines with the *(volatile foo *)& casts, 
unless of course ISO clarifies the C standard to different effect while 
we're arguing over semantics and micro-optimizations.

	-- Chris

             reply	other threads:[~2007-08-15 17:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-15 17:55 Chris Snook [this message]
2007-08-15 18:43 ` [RFP] atomic[64]_[read|set] asm implementations Russell King

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=46C33E19.3050805@redhat.com \
    --to=csnook@redhat.com \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.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).