Skip to main content

gpu_async_reactor/host/
host_adapters.rs

1// SPDX-License-Identifier: MIT OR Apache-2.0
2
3//! Hosts: the clocks, timers and idles a binary picks. The core never names one.
4//!
5//! | feature | module | what it provides |
6//! |---|---|---|
7//! | `std` | [`std_host`] | `StdClock`, `StdIdle` (thread sleep, then a word-wait park or a yield loop), `Watcher` |
8//! | `tokio` | [`tokio`] | a [`Timer`](crate::Timer) over `tokio::time` |
9//! | `io-uring` | [`uring`] | an [`Idle`](crate::Idle) whose deadline sleep is `IORING_OP_TIMEOUT` |
10
11#[cfg(feature = "std")]
12pub mod std_host;
13
14#[cfg(feature = "tokio")]
15pub mod tokio;
16
17#[cfg(all(feature = "io-uring", target_os = "linux"))]
18#[allow(unsafe_code)]
19pub mod uring;