Brian Pane wrote:
> 
> One of the known limitations of the current mod_mem_cache
> code is that it uses a single global mutex to serialize
> cache additions and deletions.

> So the other alternative I've been thinking of is to
> use an algorithm based on atomic compare-and-swap
> operations to allow thread-safe searches and updates
> of each hash chain.  I've found several references
> to lockless, concurrent linked list algorithms that
> might be suitable, for example
> http://citeseer.nj.nec.com/harris01pragmatic.html

> Anybody have opinions on this?

I like the general idea.  The details might be sticky though.  Harris's basic
algorithm looks great, but notice that he didn't include any garbage
collection/memory freeing code.   

Greg

Reply via email to