[concurrency-interest] Multi-level locks

Tim Peierls tim at peierls.net
Tue Mar 16 09:28:21 EDT 2010

On Mon, Mar 15, 2010 at 6:51 PM, David Holmes <davidcholmes at aapt.net.au>wrote:

>  There's also an example on using AQS to do Room Synchronization that we
> presented at various places, but for which I'm having trouble finding an
> actual link. :( Contact me if you'd like me to dig it up. I think there
> should be a JavaOne presentation with it in, somewhere.

I don't remember a J1 presentation, but I do remember putting together a
room synchronizer based on AQS:


I can't find any test suites with it, so I'd treat this code as more of a
sketch than a real implementation. (For example, the comment for private
static method indexMask looks wrong to me. For another, the use of a map
instead of an array to hold the room locks now strikes me as an unnecessary
and expensive nicety.)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://cs.oswego.edu/pipermail/concurrency-interest/attachments/20100316/b72f04cb/attachment-0002.html>

More information about the Concurrency-interest mailing list