mirror of
https://github.com/tokio-rs/tokio.git
synced 2025-09-28 12:10:37 +00:00
io: increase ScheduledIo
tick resolution (#6135)
While this is no current evidence that increasing the tick resolution is necessary, since we have available bits, we might as well use them.
This commit is contained in:
parent
30b2eb17c8
commit
19d96c0674
@ -165,11 +165,11 @@ enum State {
|
||||
//
|
||||
// | shutdown | driver tick | readiness |
|
||||
// |----------+-------------+-----------|
|
||||
// | 1 bit | 8 bits + 16 bits |
|
||||
// | 1 bit | 15 bits + 16 bits |
|
||||
|
||||
const READINESS: bit::Pack = bit::Pack::least_significant(16);
|
||||
|
||||
const TICK: bit::Pack = READINESS.then(8);
|
||||
const TICK: bit::Pack = READINESS.then(15);
|
||||
|
||||
const SHUTDOWN: bit::Pack = TICK.then(1);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user