🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.arch
Article #11481

Re: Atomic operations (Was Re: Living With Old Baggage)

#11481
From: Jeff Kenton OSG/UEG
Date: Mon, 06 May 1991 11:31
24 lines
1936 bytes
In article <1991May2.201917.15062@dg-rtp.dg.com>,
hamilton@siberia.rtp.dg.com (Eric Hamilton) writes:
|> In article <1991Apr22.175410.9840@decvax.dec.com>,
kenton@abyss.zk3.dec.com (Jeff Kenton OSG/UEG) writes:
|> |> 
|> |> The 88K has xmem, not test and set, which is guaranteed to be an atomic
|> |> operation (the bus is locked between the read and write cycles).  This
|> |> can be used to create locks or compare and swap without disabling
itnerrupts.
|> |> 
|> Now I'm curious.  How does one fabricate compare-and-swap out of xmem
|> without disabling interrupts?  Xmem has essentially the same restriction as
|> test-and-set, which is that the stored value must be a constant
independent of
|> the loaded value.
|> 

Once you've created a lock (with xmem) you can do almost anything within the
locked region of code without disabling interrupts.

-----------------------------------------------------------------------------
==	jeff kenton		Consulting at kenton@decvax.dec.com        ==
==	(617) 894-4508			(603) 881-0011			   ==
-----------------------------------------------------------------------------
Technical Details
Message-ID: <1991May6.113149.14531@decvax.dec.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!mips!apple!olivea!oliveb!pyramid!octopus!satyr!ditka!zinn!decvax.dec.com!abyss.zk3.dec.com!kenton
References: <336@scorpio.gtephx.UUCP> <12741@pt.cs.cmu.edu> <14628@encore.Encore.COM> <1991Apr22.175410.9840@decvax.dec.com> <1991May2.201917.15062@dg-rtp.dg.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!mips!apple!olivea!oliveb!pyramid!octopus!satyr!ditka!zinn!decvax.dec.com!abyss.zk3.dec.com!kenton
From: kenton@abyss.zk3.dec.com (Jeff Kenton OSG/UEG)
Newsgroups: comp.arch
Subject: Re: Atomic operations (Was Re: Living With Old Baggage)
Keywords: 68040 CAS2
Message-ID: <1991May6.113149.14531@decvax.dec.com>
Date: 6 May 91 11:31:49 GMT
References: <336@scorpio.gtephx.UUCP> <12741@pt.cs.cmu.edu> <14628@encore.Encore.COM> <1991Apr22.175410.9840@decvax.dec.com> <1991May2.201917.15062@dg-rtp.dg.com>
Sender: usenet@decvax.dec.com (Usenet News System)
Reply-To: kenton@abyss.zk3.dec.com (Jeff Kenton OSG/UEG)
Organization: Digital Equipment Corporation - Nashua, NH
Lines: 24
Nntp-Posting-Host: abyss.zk3.dec.com