mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-09-08 00:00:13 +02:00
wip
This commit is contained in:
@@ -1,7 +1,6 @@
|
|||||||
use crate::runtime::{Config, MetricsBatch, WorkerMetrics};
|
use crate::runtime::{Config, MetricsBatch, WorkerMetrics};
|
||||||
|
|
||||||
use std::cmp;
|
use std::cmp;
|
||||||
use std::f32::consts::E;
|
|
||||||
use std::time::{Duration, Instant};
|
use std::time::{Duration, Instant};
|
||||||
|
|
||||||
/// Per-worker statistics. This is used for both tuning the scheduler and
|
/// Per-worker statistics. This is used for both tuning the scheduler and
|
||||||
|
|||||||
@@ -826,6 +826,9 @@ impl Worker {
|
|||||||
#[cfg(loom)]
|
#[cfg(loom)]
|
||||||
const ROUNDS: usize = 1;
|
const ROUNDS: usize = 1;
|
||||||
|
|
||||||
|
debug_assert!(core.lifo_slot.is_none());
|
||||||
|
debug_assert!(core.run_queue.is_empty());
|
||||||
|
|
||||||
if !self.transition_to_searching(cx, core) {
|
if !self.transition_to_searching(cx, core) {
|
||||||
return None;
|
return None;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ use std::task::{Context, Poll, Waker};
|
|||||||
/// Any changes to the layout of this struct _must_ also be reflected in the
|
/// Any changes to the layout of this struct _must_ also be reflected in the
|
||||||
/// const fns in raw.rs.
|
/// const fns in raw.rs.
|
||||||
#[repr(C)]
|
#[repr(C)]
|
||||||
|
#[repr(align(128))]
|
||||||
pub(super) struct Cell<T: Future, S> {
|
pub(super) struct Cell<T: Future, S> {
|
||||||
/// Hot task state data
|
/// Hot task state data
|
||||||
pub(super) header: Header,
|
pub(super) header: Header,
|
||||||
|
|||||||
Reference in New Issue
Block a user