0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-06-17 09:28:21 +02:00

ircd::fs::aio: Remove blocking debug; deprecated by io_uring.

This commit is contained in:
Jason Volk 2020-04-18 20:17:37 -07:00
parent 9fce3c6ca6
commit 26b36d4740

View file

@ -201,46 +201,11 @@ ircd::fs::aio::read(const fd &fd,
const scope_count cur_reads{stats.cur_reads};
stats.max_reads = std::max(stats.max_reads, stats.cur_reads);
#if defined(RWF_NOWAIT) && defined(RB_DEBUG_FS_AIO_READ_BLOCKING)
request.aio_rw_flags |= support::nowait? RWF_NOWAIT : 0;
#endif
size_t bytes
{
request()
};
#if defined(RWF_NOWAIT) && defined(RB_DEBUG_FS_AIO_READ_BLOCKING)
const bool would_block
{
opts.blocking &&
request.aio_rw_flags & RWF_NOWAIT &&
request.retval == -1 &&
request.errcode == EAGAIN
};
if(would_block)
{
log::dwarning
{
log, "read blocks io_submit(): fd:%d size:%zu off:%zd op:%u pri:%u in_flight:%zu qcount:%zu",
request.aio_fildes,
request.aio_nbytes,
request.aio_offset,
request.aio_lio_opcode,
request.aio_reqprio,
system->in_flight,
system->qcount,
};
assert(bytes == 0);
request.aio_rw_flags &= ~RWF_NOWAIT;
request.retval = -2;
request.errcode = 0;
bytes = request();
}
#endif
stats.bytes_read += bytes;
stats.reads++;
return bytes;