Re: Possible unneccessary IORING_OP_READs executed in Async

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2021-06-07 at 16:26 -0400, Olivier Langlois wrote:
> In __io_queue_sqe():
> a) io_issue_sqe() returns EAGAIN
> b) in between io_issue_sqe() call and vfs_poll() call done inside
> io_arm_poll_handler(), data becomes available
> c) io_arm_poll_handler() returns false because vfs_poll() did return
> an
> non-empty mask.
> 
> I am throwing this idea to the group.
> Would it be a good idea to detect that situation and recall
> io_issue_sqe() in that case instead of pushing the request to the io-
> wq?
> 
> On busy TCP sockets, this scenario seems to happen very often (ie:
> few
> times every second)

I didn't wait for an answer and I went straight to trying out an
io_uring modification.

It works like a charm. My code is using io_uring like a maniac and with
the modification, zero io worker threads get created.

That means a definite gain in terms of latency...

I will send out a patch soon to share this discovery with io_uring
devs.

Greetings,





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux