refactor: access ThreadContext through CurrentThread(), ci: switch Bitcoin Core to master #323

pull Sjors wants to merge 2 commits into bitcoin-core:master from Sjors:2026/07/pr318-minimal changing 6 files +51 −27
  1. Sjors commented at 11:46 AM on July 29, 2026: member

    This is a minimal subset from #318 needed to match the shim introduced by https://github.com/bitcoin/bitcoin/pull/35084. Should unblock #322, see #322 (comment).

    Include #322 here, because CI will not pass now since https://github.com/bitcoin/bitcoin/pull/35084 merged.

  2. refactor: access ThreadContext through CurrentThread()
    Introduce CurrentThread() as an accessor for the existing namespace-scope thread_local object and migrate internal callers to it. This does not change storage duration, initialization, destruction, the exported TLS symbol, or its lint suppressions.
    
    Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
    86b4810501
  3. DrahtBot commented at 11:46 AM on July 29, 2026: none

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process.

    If your review is incorrectly listed, please copy-paste <code>&lt;!--meta-tag:bot-skip--&gt;</code> into the comment that the bot should ignore.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  4. ci: Switch back to Bitcoin Core's master branch
    bitcoin/bitcoin#35084 has now been merged.
    66298c737f
  5. Sjors renamed this:
    refactor: access ThreadContext through CurrentThread()
    refactor: access ThreadContext through CurrentThread(), ci: switch Bitcoin Core to master
    on Jul 29, 2026
  6. hebasto approved
  7. hebasto commented at 12:09 PM on July 29, 2026: member

    ACK 66298c737f43b12009e25396383aeb98b6c8164b.

  8. xyzconstant commented at 2:19 PM on July 29, 2026: contributor

    ACK 66298c737f43b12009e25396383aeb98b6c8164b

  9. ViniciusCestarii commented at 6:50 PM on July 29, 2026: contributor

    ACK 66298c737f43b12009e25396383aeb98b6c8164b

  10. ryanofsky approved
  11. ryanofsky commented at 2:04 PM on July 30, 2026: collaborator

    Code review ACK 66298c737f43b12009e25396383aeb98b6c8164b. This nicely separates the CurrentThread refactoring from the mingw bug workaround. But it's misleading to call this a minimal fix for compatibility, because a minimal fix would just be:

    --- a/include/mp/proxy-io.h
    +++ b/include/mp/proxy-io.h
    @@ -934,6 +934,10 @@ extern thread_local ThreadContext g_thread_context; // NOLINT(bitcoin-nontrivial
     // cannot be thread_local" which should not be a problem on modern platforms, and
     // could lead to a small memory leak at worst on older ones.
    
    +inline ThreadContext& CurrentThread()
    +{
    +    return g_thread_context;
    +}
     } // namespace mp
    
     #endif // MP_PROXY_IO_H
    
  12. ryanofsky merged this on Jul 30, 2026
  13. ryanofsky closed this on Jul 30, 2026


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/libmultiprocess. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-08-05 20:30 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me