mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Davide Libenzi <davidel@xmailserver.org>
To: "Boehm, Hans" <hans_boehm@hp.com>
Cc: "'Arjan van de Ven'" <arjanv@redhat.com>,
	Hans Boehm <Hans.Boehm@hp.com>,
	"MOSBERGER, DAVID (HP-PaloAlto,unix3)" <davidm@hpl.hp.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-ia64@linuxia64.org
Subject: RE: [Linux-ia64] Re: web page on O(1) scheduler
Date: Sat, 24 May 2003 07:43:12 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.55.0305240716230.3978@bigblue.dev.mcafeelabs.com> (raw)
In-Reply-To: <Pine.LNX.4.55.0305232225010.3538@bigblue.dev.mcafeelabs.com>

On Fri, 23 May 2003, Davide Libenzi wrote:

> You need a write memory barrier even on the unlock. Consider this :
>
> 	spinlock = 1;
> 	...
> 	protected_resource = NEWVAL;
> 	spinlock = 0;
>
> ( where spinlock = 0/1 strip down, but do not lose the concept, the lock
> operation ). If a CPU reorder those writes, another CPU might see the lock
> drop before the protected resource assignment. And this is usually bad
> for obvious reasons.

David made me notice about a brain misfire here. You need protection even
for loads crossing the unlock. For the same obvious reasons :) Yes, a
realease barrier will be sufficent for ia64, while you'll need an mfence
on P4.



- Davide


  reply	other threads:[~2003-05-24 14:30 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-24  0:53 Boehm, Hans
2003-05-24  5:38 ` Davide Libenzi
2003-05-24 14:43   ` Davide Libenzi [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-05-24  0:10 Boehm, Hans
2003-05-24  0:20 ` Davide Libenzi
2003-05-23 17:48 Boehm, Hans
2003-05-23 18:04 ` Davide Libenzi
2003-05-21  6:49 David Mosberger
2003-05-21  9:01 ` Arjan van de Ven
2003-05-21 10:40   ` [Linux-ia64] " Duraid Madina
2003-05-21 10:43     ` Christoph Hellwig
2003-05-21 13:12     ` Arjan van de Ven
2003-05-21 13:51       ` Olivier Galibert
2003-05-28 22:12         ` Bill Davidsen
     [not found]         ` <Pine.LNX.3.96.1030528180909.21414B-100000@gatekeeper.tmr.c om>
2003-05-29  5:59           ` Mike Galbraith
2003-06-02  8:05             ` Ingo Molnar
2003-06-04  4:07               ` Bill Davidsen
     [not found]             ` <Pine.LNX.4.44.0306020949520.3375-100000@localhost.localdom ain>
2003-06-02 13:51               ` Mike Galbraith
2003-06-04  3:52             ` Bill Davidsen
2003-06-04  4:55               ` David Schwartz
     [not found]             ` <Pine.LNX.3.96.1030603234616.16495B-100000@gatekeeper.tmr.c om>
2003-06-04  7:13               ` Mike Galbraith
2003-06-04 15:30                 ` Jan Harkes
2003-05-21 19:18       ` Duraid Madina
2003-05-21 20:03         ` Helge Hafting
2003-05-21 22:59         ` Alan Cox
2003-05-23  1:07   ` Hans Boehm
2003-05-23  8:30     ` Arjan van de Ven

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=Pine.LNX.4.55.0305240716230.3978@bigblue.dev.mcafeelabs.com \
    --to=davidel@xmailserver.org \
    --cc=Hans.Boehm@hp.com \
    --cc=arjanv@redhat.com \
    --cc=davidm@hpl.hp.com \
    --cc=hans_boehm@hp.com \
    --cc=linux-ia64@linuxia64.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

all inboxes | Powered by JetHome®