Re: [Boost-users] [multi_index] Core dump in multi-index library !!

----- Mensaje original -----
De: Patel Priyank-PPATEL1
Hi Joaquin, [...] One other thing, addition and deletionIs done by separate threads in my application.
Oh, oh. multi_index_container is *not* thread safe, so this smells like the problem --and it is not, it certainly has the potential to crash your app sooner or later. Please take into account thread unsafety extends to every member function of multi_index_container, so you'd better lockguard *every* public method of Procedure_Pool. Looking fwd to knowing your results. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo In case you're wondering, STL implementations typically have the same level of thread safety as B.MI provides: 1. Concurrent access to different containers is safe. 2. Concurrent read-only access to the same container is safe. The rationale is that locking every public method of an STL container adds an unavoidable runtime overhead (you might not need it), and moreover it doesn't necessarily map to what constitutes *atomicity* to a given app --in your case, for instance, atomicity, and thus lockguarding, is best done at the level of Procedue_Pool interface.
participants (1)
-
JOAQUIN LOPEZ MU?Z