summaryrefslogtreecommitdiffstats
path: root/tokio/src/util/mod.rs
diff options
context:
space:
mode:
authorCarl Lerche <me@carllerche.com>2020-03-05 10:31:37 -0800
committerGitHub <noreply@github.com>2020-03-05 10:31:37 -0800
commita78b1c65ccfb9692ca5d3ed8ddde934f40091d83 (patch)
treec88e547d6913b204f590aea54dc03328ee3cb094 /tokio/src/util/mod.rs
parent5ede2e4d6b2f732e83e33f9693682dffc6c9f5b0 (diff)
rt: cleanup and simplify scheduler (scheduler v2.5) (#2273)
A refactor of the scheduler internals focusing on simplifying and reducing unsafety. There are no fundamental logic changes. * The state transitions of the core task component are refined and reduced. * `basic_scheduler` has most unsafety removed. * `local_set` has most unsafety removed. * `threaded_scheduler` limits most unsafety to its queue implementation.
Diffstat (limited to 'tokio/src/util/mod.rs')
-rw-r--r--tokio/src/util/mod.rs13
1 files changed, 7 insertions, 6 deletions
diff --git a/tokio/src/util/mod.rs b/tokio/src/util/mod.rs
index 2761f725..c2f572f1 100644
--- a/tokio/src/util/mod.rs
+++ b/tokio/src/util/mod.rs
@@ -3,17 +3,18 @@ cfg_io_driver! {
pub(crate) mod slab;
}
-cfg_sync! {
- pub(crate) mod linked_list;
-}
+#[cfg(any(feature = "sync", feature = "rt-core"))]
+pub(crate) mod linked_list;
#[cfg(any(feature = "rt-threaded", feature = "macros", feature = "stream"))]
mod rand;
-cfg_rt_threaded! {
- mod pad;
- pub(crate) use pad::CachePadded;
+cfg_rt_core! {
+ mod wake;
+ pub(crate) use wake::{waker_ref, Wake};
+}
+cfg_rt_threaded! {
pub(crate) use rand::FastRand;
mod try_lock;