On 24 Jun 2009, at 06:19, Mathias Froehlich wrote: > Log Message: > Provide a thread safe SGWeakPtr implementation. > Extend SGAtomic with atomic exchange and add. > Import updates from the original implementation of that in OpenFDM.
An observation: this change has stopped SGAtomic being (by default) a proxy for osg/OpenThreads Atomic. There's a downside to this - OpenThreads Atomic has a specialisation (not of the template kind, but the #ifdef kind) for OS-X atomics - _OPENTHREADS_ATOMIC_USE_BSD_ATOMIC. On Mac we're still on GCC version 4.0 by default [1], so we don't get the GCC built-in case for SGAtomic and friends - and will fall back to a pthread-mutex implementation. I know there's an argument for having Simgear not depend on OSG, which I agree with, and I know it's awkward to depend on OpenThreads when it's typically only distributed as part of the OSG tree, it just seems like a step backwards - I'd prefer to delegate all thread support to OpenThreads and maintain less code ourselves. [1] - yes, it's ridiculous that the stock compiler is still 4.0. A newer version (4.2) is available, but I'm hesitant to switch to it when the system compiler is still 4.0. James ------------------------------------------------------------------------------ _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel