Different vftable size for boost::detail::shared_state_base regarding BOOST_THREAD_PROVIDES_FUTURE_CONTINUATION
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Start in thread/include/boost/thread/future.hpp around line 327 and compare the shared_state_base code with the precautions around lines 285 and 304. Verify mixed modules with and without BOOST_THREAD_PROVIDES_FUTURE_CONTINUATION no longer produce differing vftable layouts or the reported linker warning.
Written by the indexing model from the issue text.
Description
Version of Boost: All of them, including 'master'
File: thread/include/boost/thread/future.hpp , around line 327
The matter is that this file contains the following portion of code (class boost::detail::shared_state_base):
#if defined BOOST_THREAD_PROVIDES_FUTURE_CONTINUATION
virtual void set_continuation_ptr(continuation_ptr_type continuation, boost::unique_lock<boost::mutex>& lock)
{
continuations.push_back(continuation);
if (done) {
do_continuation(lock);
}
}
#endif
So the vftable layout depends on BOOST_THREAD_PROVIDES_FUTURE_CONTINUATION macro, which leads to linker warning (and unpredictable runtime outcomes) when mixing code from two different modules, with only one of them using that macro.
There are some precautions about this issue before (see ll.285 and 304). It would be nice to have the same here.
- Dominant language
- C++
- Stars
- 213
- Forks
- 171
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from boostorg/thread
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
-
Difficulty 3/5 1-2 days Newbie friendliness 64/100
-
Difficulty 3/5 1-2 days Newbie friendliness 42/100
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 58/100
Similar issues
-
enhancement
Difficulty 1/5 Under an hour Newbie friendliness 88/100
QuantStack/git2cpp#187 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
mlcommons/mobile_app_open#1182 ·
-
Needs-Triage
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
microsoft/winget-cli#6547 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
AXERA-TECH/ax-llm#77 ·