Boost logo

Boost :

From: Chris Thomasson (cristom_at_[hidden])
Date: 2006-10-30 09:15:54


"Anthony Williams" <anthony_w.geo_at_[hidden]> wrote in message
news:hcxmjaqw.fsf_at_yahoo.com...
> Roland Schwarz <roland.schwarz_at_[hidden]> writes:

[...]

> * Contention on the map. Ideally we don't want to have any contention for
> unrelated mutexes. Chris Thomasson has suggested using a global lock-free
> hashmap for this sort of thing.

You have got to be careful when you make use of this technique...

http://groups.google.com/group/comp.programming.threads/msg/56406d367ac85dcb

You either have to know exactly what your are doing (e.g., only use hashmap
the in your libraries system api), or by following another simple method:

http://groups.google.com/group/comp.programming.threads/browse_frm/thread/e0c011baf08844c4

other than those caveats, using a global hashmap for this sort of thing
usually works out fine.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk