Signals not received when building with link time optimization enabled and using asio as static library
- Dominant language
- C++
- Stars
- 1.6k
- Forks
- 485
- PR merge metrics
- No merged PRs in 30d
Description
We are using asio as a static library instead of header only, boost version 1.78. We instantiate a `boost::asio::signal_set` in the main thread of our application but do not receive any signals when building with link time optimization enabled (using gcc9/10). With making `get_signal_state()` (signal_set_service.ipp) `BOOST_NOINLINE` the issue does not occur and signals are again received properly.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with signal_set_service.ipp and inspect get_signal_state() in the static-library build path. Reproduce the issue with Boost 1.78, GCC 9 or 10, link-time optimization, and asio signal_set in the main thread. Done means signals are received reliably without requiring the reported workaround.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100