* Yet another lock-free reader/writer lock
@ 2005-12-01 1:40 Joe Seigh
0 siblings, 0 replies; only message in thread
From: Joe Seigh @ 2005-12-01 1:40 UTC (permalink / raw)
To: linux-kernel
I have another lock-free algorithm on my FOSS project site
http://atomic-ptr-plus.sourceforge.net/
It's the rcpc (reference counted proxy collector) package.
It uses double wide compare and swap, load reserved/store conditional,
or single wide compare and swap where the former aren't available,
e.g. 64 bit sparc. Which pretty much makes it portable to practically
anything in any environment, kernel or user space.
One caveat. It's probably not safe to use the single wide compare and
swap for 32 bit words if there's a possibility that a read lock will be
held long enough for a 30 bit counter to wrap. But it's probably safe if
the reader does not preempt.
It's ported to 32 bit x86 (linux) and 32 bit ppc (OSX) which is the
only development platforms I have access to. I may port it back to
win32 where I did the initial prototype (it's a vc++ vs. gcc port).
--
Joe Seigh
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-12-01 1:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-12-01 1:40 Yet another lock-free reader/writer lock Joe Seigh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox