Re: [Boost-bugs] [Boost C++ Libraries] #9355: boost::coroutine crash in base<void>::pull_coroutine_base<void> with multiple threads

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #9355: boost::coroutine crash in base<void>::pull_coroutine_base<void> with multiple threads
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-11-09 18:07:46


#9355: boost::coroutine crash in base<void>::pull_coroutine_base<void> with
multiple threads
-------------------------------+----------------------------------------
  Reporter: craig@… | Owner: olli
      Type: Bugs | Status: closed
 Milestone: To Be Determined | Component: coroutine
   Version: Boost 1.55.0 | Severity: Problem
Resolution: worksforme | Keywords: pull_coroutine_base; crash
-------------------------------+----------------------------------------

Comment (by Craig Hutchinson <craig@…>):

 Okay so I have tested a Haswell i5-4670 and with 2 thread the issue too
 53,161 executions to occur, however up the test to 4 threads and the crash
 occurs every 2-4 executions! I don't know that that really indicates as on
 the i7 two threads was causing the issue so could be amplified by hyper-
 threading somehow.

 I don't like the 'fix' but putting a mutex lock around the constructor for
 the coroutine is the only work around I have currently found
 {{{
 {
 boost::lock_guard<boost::recursive_mutex> lock(m_guard);
 coro_t::pull_type( boost::bind( foo, _1, i) );
 }
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/9355#comment:11>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:14 UTC