Boost logo

Threads-Devel :

Subject: [Threads-devel] Boost Threads - interest in other thread-related classes?
From: Gregory Peele ARA/CFD (gpeele_at_[hidden])
Date: 2009-01-13 11:57:54


On a more positive note (sorry for sounding a little antagonistic in my
last post... debugging that deadlock for two days did not put me in a
good mood) would there be any interest in augmenting the Boost Threads
library with additional concurrency-related classes?

In particular, I developed macros for cross-platform memory barriers, a
template class for atomic-access variables (with subclasses for atomic
integer arithmetic and atomic type-safe enums), a producer/consumer
queue based on boost::circular_buffer, a simple monitor lock class that
wraps a boost::recursive_mutex and boost::condition_variable_any, a
semaphore, and STL-conformant containers that synchronize multithreaded
access to the STL list, vector, set, and map (or any other container
classes that implement the same interface.)

I'm not sure if my employer will allow me to submit my existing code to
Boost (our customer is not very friendly to submitting code to open
source projects,) but if there is any interest, I could probably rewrite
it from scratch relatively quickly. The atomics and memory barriers
rely on compiler support (present in Visual Studio 2003+ and GCC 4.1+)
but assembly versions could be written for other targets. Everything
else should be completely portable as it relies entirely on Boost or the
atomic templates. This code is fully unit tested, but I suppose there
still could be unknown race conditions.

Thanks,
Greg Peele
Applied Research Associates, Inc.


Threads-Devel list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk