|
JH-Toolkit v1.4.1
An engineering-oriented C++20 toolkit with duck-typed concepts, static design, async coroutines, and semantic containers — header-only, RTTI-free, and concurrency-friendly.
|
Forward-aggregator header for all jh::*_pools.
More...
Go to the source code of this file.
Forward-aggregator header for all jh::*_pools.
This header provides the canonical include entry for jh::*_pool<...>s — a high-level, user facing around jh::conc::*_pool<...> pool bases.
#include <jh/pool>Internally, it includes the user facing pool interfaces from jh/concurrent/*.h and exposes them collectively.
Platform Semantics
All pool implementations in <jh/pool> are designed to be data-race-free at the algorithmic level.
The concurrency design assumes a strong acquire/release synchronization contract between:
On POSIX platforms (Linux / Darwin), this assumption is satisfied by mature implementations built upon:
pthread_rwlock futex-based primitives Under these environments, the synchronization graph forms a complete happens-before closure in practice. The pools are considered engineering-grade well-formed and have demonstrated stable high-concurrency behavior.
The design intentionally leverages these stronger implementation semantics. It does not restrict itself to the minimal guarantees of the ISO C++ abstract machine, as doing so would significantly reduce expressiveness or introduce prohibitive synchronization overhead.
Windows Support
Windows is treated as a secondary platform.
While the code remains data-race-free at the C++ level, certain combinations of:
have been observed under extreme concurrency to exhibit rare visibility gaps or ordering jitter.
These effects appear to stem from subtle differences in how C++ atomic semantics interact with Windows runtime synchronization primitives. In particular, control blocks associated with weak_ptr, shared_ptr, or atomic reference counters may not always participate in a fully closed visibility chain under high parallel pressure.
Additional fences are introduced on Windows builds to strengthen ordering, but they cannot eliminate all anomalies when interacting with certain runtime configurations.
Therefore:
The primary validation and release target of this toolkit remains POSIX systems (Linux + GCC/Clang, Darwin + Clang).