Re: [Boost-bugs] [Boost C++ Libraries] #11256: future<>::is_ready() == false in continuation function

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #11256: future<>::is_ready() == false in continuation function
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-05-02 19:21:34


#11256: future<>::is_ready() == false in continuation function
-------------------------------------+-------------------------------------
  Reporter: Konrad Zemek | Owner: viboes
  <konrad.zemek@…> | Status: assigned
      Type: Bugs | Component: thread
 Milestone: To Be Determined | Severity: Problem
   Version: Boost 1.58.0 | Keywords: then continuation
Resolution: | is_ready
-------------------------------------+-------------------------------------

Comment (by Konrad Zemek <konrad.zemek@…>):

 Here's the trace for the {{{boost::lock}}} exception (Boost.Thread from
 commit e598796eaf, i.e. current develop):

 {{{
 terminate called after throwing an instance of
 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::lock_error>
>'
   what(): boost unique_lock owns already the mutex: Resource deadlock
 avoided

 Program received signal SIGABRT, Aborted.
 0x00007ffff70ffe37 in __GI_raise (sig=sig_at_entry=6) at
 ../nptl/sysdeps/unix/sysv/linux/raise.c:56
 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or
 directory.
 (gdb) bt
 #0 0x00007ffff70ffe37 in __GI_raise (sig=sig_at_entry=6) at
 ../nptl/sysdeps/unix/sysv/linux/raise.c:56
 #1 0x00007ffff7101528 in __GI_abort () at abort.c:89
 #2 0x00007ffff770505d in __gnu_cxx::__verbose_terminate_handler() () from
 /usr/lib/x86_64-linux-gnu/libstdc++.so.6
 #3 0x00007ffff7702ed6 in ?? () from /usr/lib/x86_64-linux-
 gnu/libstdc++.so.6
 #4 0x00007ffff7702f21 in std::terminate() () from /usr/lib/x86_64-linux-
 gnu/libstdc++.so.6
 #5 0x00007ffff7703139 in __cxa_throw () from /usr/lib/x86_64-linux-
 gnu/libstdc++.so.6
 #6 0x0000000000411f65 in boost::throw_exception<boost::lock_error>
 (e=...) at /usr/include/boost/throw_exception.hpp:69
 #7 0x00000000004146e6 in boost::unique_lock<boost::mutex>::lock
 (this=0x7fffffffe480) at thread/include/boost/thread/lock_types.hpp:343
 #8 0x000000000040adcb in
 boost::detail::make_future_executor_continuation_shared_state<boost::executors::basic_thread_pool,
 boost::future<boost::future<void> >, void,
 stepTwo(boost::executors::basic_thread_pool&)::<lambda(auto:2)>
>(boost::executors::basic_thread_pool &, boost::unique_lock<boost::mutex>
 &, <unknown type in /home/kzemek/plgrid/helpers/example, CU 0x0, DIE
 0x3d241>, <unknown type in /home/kzemek/plgrid/helpers/example, CU 0x0,
 DIE 0x3d21b>) (ex=..., lock=...,
     f=<unknown type in /home/kzemek/plgrid/helpers/example, CU 0x0, DIE
 0x3d241>, c=<unknown type in /home/kzemek/plgrid/helpers/example, CU 0x0,
 DIE 0x3d21b>)
     at thread/include/boost/thread/future.hpp:4703
 #9 0x000000000040aad0 in boost::future<boost::future<void>
>::then<boost::executors::basic_thread_pool,
 stepTwo(boost::executors::basic_thread_pool&)::<lambda(auto:2)>
>(boost::executors::basic_thread_pool &, <unknown type in
 /home/kzemek/plgrid/helpers/example, CU 0x0, DIE 0x37065>)
 (this=0x7fffffffe4e0, ex=...,
     func=<unknown type in /home/kzemek/plgrid/helpers/example, CU 0x0, DIE
 0x37065>) at thread/include/boost/thread/future.hpp:4874
 #10 0x000000000040a872 in stepTwo (executor=...) at example.cpp:30
 #11 0x000000000040a901 in main () at example.cpp:36
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/11256#comment:5>
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:18 UTC