1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
//! `proxima::sync` — runtime-agnostic concurrency primitives shaped like
//! `tokio::sync`. Users get the API surface they expect (`use
//! proxima_primitives::sync::Mutex;`) without pulling tokio. Backing crates are
//! `futures` (channels, lock::Mutex), `async-lock` (RwLock, Semaphore),
//! `event-listener` (Notify), and `async-broadcast` (watch, broadcast).
//!
//! The trait set re-exported here is *concurrency-defining*; runtime
//! coupling (spawn, timers, per-core context) stays on the
//! `Runtime` trait. See the proxima-tokio-elimination-library plan (P1.3).
//!
//! Tier: `notify`, `oneshot`, `shutdown`, and `AsyncMutex` (the
//! `async-mutex` feature) compile under `no_std + alloc` (each backing
//! crate has a no_std + alloc path; see DC-SYNC). The `watch` primitive
//! uses `std::sync::RwLock<T>` for its value cache and is gated behind
//! the `std` feature, as are the other remaining primitives (mpsc,
//! mutex, once_cell, rwlock, semaphore, broadcast) — full no_std + alloc
//! landing for those is deferred per DC-SYNC.
//!
//! [`blocking`] and [`task`] fold in the former `proxima-lock` and
//! `proxima-task` crates (Workstream F, RISC-dedup) — one runtime-agnostic
//! concurrency/task crate instead of three.
// Backing crates (async-*, event-listener, futures) expose no_std + alloc
// surfaces but the cliff requires per-crate feature-flag analysis to make
// the proxima-sync API surface available under no_std. `notify` + `oneshot`
// have made that crossing (see their `alloc` gates below); the remaining
// primitives still gate behind `std` pending the same per-crate analysis.
// Full no_std + alloc landing for those is deferred per DC-SYNC.
// alloc-tier (not std): only notify's AtomicBool/Ordering re-exports are
// reachable here without std; watch.rs is the sole consumer of this module's
// std-only RwLock re-export, and stays std-gated internally (see below).
// re-gated from std to alloc: both event-listener and the AtomicBool it
// backs support no_std + alloc, so prime can depend on Notify without
// pulling proxima-primitives/std (and its tokio dependency) at all.
// re-gated from std to alloc: futures::channel::oneshot has no runtime
// coupling and compiles no_std + alloc.
// not part of the Notify/watch loom protocol; its regular
// proxima-runtime `tokio` feature dependency pulls tokio, which the loom
// build keeps tokio-free.
// cross-core graceful shutdown (folded in from the former proxima-shutdown
// satellite crate) — its ResourceRegistry primitive is no_std + alloc; the
// ambient std convenience and ShutdownBarrier gate on `std` internally.
/// Multi-party rendezvous, shape-compatible with `tokio::sync::Barrier`.
/// Direct re-export of `async_lock::Barrier`. `wait()` resolves once
/// `N` tasks have called it. Useful for staged pipeline startup
/// (every worker reaches a barrier together) and integration tests.
pub use Barrier;
pub use ;
pub use ;
pub use ;
pub use ;
pub use OnceCell;
pub use ;
pub use ;