Re: [asio-users] Hanging in poll_one
Brought to you by:
chris_kohlhoff
From: Gruenke, M. <mgruenke@Tycoint.com> - 2012-12-21 19:36:36
|
Perhaps it would help if you could submit a concise example that demonstrates the problem. At minimum, please submit a call stack with debug info maxed out (at least enough that we get line numbers & filenames) and all optimizations & inlining disabled. Also, please state the specific version of Boost you're using. Matt -----Original Message----- From: Dan Posluns [mailto:da...@da...] Sent: December 21, 2012 13:50 To: asi...@li... Subject: [asio-users] Hanging in poll_one Hi there, I'm using boost::io_service to manage cross-platform multithreading tasks for iOS and Android NDK. Occasionally, I get hangs on either platform. My latest problem is io_service::poll_one on Android, which hangs with the following callstack: (std::__atomic0::__atomic_base<long>::load(std::memory_order) const+44) #02 pc 00454f1c /data/app-lib/com.decarta.myditu.nav-1/libnavlib.so (std::__atomic0::__atomic_base<long>::operator long() const+20) #03 pc 0044deac /data/app-lib/com.decarta.myditu.nav-1/libnavlib.so (boost::asio::detail::task_io_service::poll_one(boost::system::error_code&)+60) I had a similar problem with io_service::run_one on iOS, where the single worker thread would occasionally hang in pthread_cond_wait() no matter how many times I called post() on the service from a different thread. I switched to a poll_one() implementation with my own condition lock to circumvent it on that platform, but the bug remains. I love the functionality of Boost.Asio but these hangs are killing me, especially on Android. They are extremely infrequent but I have no clue what I can do about them. (We are using gnustl for our standard library in NDK.) Any advice? Thanks, Dan. ------------------------------------------------------------------------------ LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial Remotely access PCs and mobile devices and provide instant support Improve your efficiency, and focus on delivering more value-add services Discover what IT Professionals Know. Rescue delivers http://p.sf.net/sfu/logmein_12329d2d _______________________________________________ asio-users mailing list asi...@li... https://lists.sourceforge.net/lists/listinfo/asio-users _______________________________________________ Using Asio? List your project at http://think-async.com/Asio/WhoIsUsingAsio |