From: Olivier Langlois <[email protected]>
To: Jens Axboe <[email protected]>
Cc: Pavel Begunkov <[email protected]>,
Hao Xu <[email protected]>,
io-uring <[email protected]>,
linux-kernel <[email protected]>
Subject: Re: [PATCH v1] io_uring: Add support for napi_busy_poll
Date: Mon, 21 Feb 2022 14:29:59 -0500 [thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
On Sun, 2022-02-20 at 12:38 -0700, Jens Axboe wrote:
>
> OK, that's a pretty good improvement in both latency and
> deviation/consistency. Is this using SQPOLL, or is it using polling
> off
> cqring_wait from the task itself? Also something to consider for the
> test benchmark app, should be able to run both (which is usually just
> setting the SETUP_SQPOLL flag or not, if done right).
>
>
The answer to your question is complex. This is one of the external
factor that I was refering too.
1 thread is managing 49 TCP sockets. This thread io_uring context is
configured with SQPOLL. Upon receiving a packet of interest, it will
wake up thread #2 with an eventfd installed into a private non SQPOLL
io_uring context and will send a request to a 50th TCP socket.
Both threads are now busy polling NAPI. One from the SQPOLL code and
the other with the io_cqring_wait() code.
If it was not enough, since I have discovered busy poll benefits and
that to reschedule a sleeping task takes about 5-10 uSecs, thread #1 is
also busy polling io_uring instead of blocking in io_uring_enter().
Thx for suggesting designing the benchmark to be able to test both
SQPOLL and non SQPOLL busy polling. This is something that I already in
mind.
I have completed 3 small improvements for the patch v2. I need to check
the kernel test bot and Hao comments to see if I have more to work on
but if all is good, I only need to complete the benchmark program. I
might able to send v2 later today.
Greetings,
next prev parent reply other threads:[~2022-02-21 19:30 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-19 8:03 [PATCH v1] io_uring: Add support for napi_busy_poll Olivier Langlois
2022-02-19 21:42 ` Olivier Langlois
2022-02-20 0:22 ` Jens Axboe
2022-02-20 18:37 ` Olivier Langlois
2022-02-20 19:38 ` Jens Axboe
2022-02-21 19:29 ` Olivier Langlois [this message]
2022-02-21 5:25 ` Hao Xu
2022-02-20 20:51 ` kernel test robot
2022-02-20 21:53 ` kernel test robot
2022-02-20 21:53 ` kernel test robot
2022-02-21 5:23 ` Hao Xu
2022-02-25 5:32 ` Olivier Langlois
2022-02-25 15:32 ` Olivier Langlois
2022-02-28 18:34 ` Hao Xu
2022-02-28 21:20 ` Olivier Langlois
2022-03-01 3:53 ` Hao Xu
2022-02-28 18:26 ` Hao Xu
2022-02-28 21:01 ` Olivier Langlois
2022-03-01 8:23 ` Hao Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cfa4268754a9884d22ac901a42817716ee33ab5f.camel@trillion01.com \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox