mirror of
https://github.com/matrix-construct/construct
synced 2024-11-04 21:08:57 +01:00
ircd::fs: Add a nodelay option on reads.
This commit is contained in:
parent
7a9d70f15d
commit
444000faf1
2 changed files with 6 additions and 0 deletions
|
@ -63,6 +63,11 @@ struct ircd::fs::read_opts
|
|||
/// an exception will be thrown. We default to true because we have faith
|
||||
/// in the useful propagation of an exception for this event.
|
||||
bool interruptible {true};
|
||||
|
||||
/// Submits the I/O request immediately rather than allowing IRCd to
|
||||
/// queue requests for a few iterations of the ircd::ios event loop.
|
||||
/// (only relevant to aio).
|
||||
bool nodelay {false};
|
||||
};
|
||||
|
||||
inline
|
||||
|
|
|
@ -503,6 +503,7 @@ noexcept try
|
|||
// non-reading events, even for different files and locations. It may
|
||||
// be possible to optimize this condition.
|
||||
|| request.aio_lio_opcode != IOCB_CMD_PREADV
|
||||
|| request.ropts->nodelay
|
||||
};
|
||||
|
||||
if(flush_now)
|
||||
|
|
Loading…
Reference in a new issue