From: axboe@kernel.dk (Jens Axboe)
Subject: [PATCH] NVMe: Add rw_page support
Date: Thu, 13 Nov 2014 18:29:37 -0700 [thread overview]
Message-ID: <54655B01.9090206@kernel.dk> (raw)
In-Reply-To: <1415923538-18760-1-git-send-email-keith.busch@intel.com>
On 2014-11-13 17:05, Keith Busch wrote:
> This adds the rw_page entry point to the nvme driver so a page can be
> written/read without going through the block layer and not requiring
> additional allocations.
>
> Just because we implement this doesn't mean we want to use it. I only see
> a performance win on some types of work, like swap where I see about 15%
> reduction in system time (compared to 20% prior to blk-mq when we didn't
> allocate a request to get a command id). Even then, system time accounts
> for very little of the real time anyway, and it's only an over-all win
> if the device has very low-latency. But the driver doesn't know this
> nor if the expected workload will even benefit from using page io,
> so I added a queue flag that a user can toggle on/off.
Of the reduced system time, where was that spent?
> The other benefit besides reduced system time is that we can swap
> pages in/out without having to allocate anything since everything is
> preallocated in this path.
I have an iod prealloc patch that gets rid of the last kmalloc/kfree in
the IO path for nvme, for smaller IO (defaults to 8KB, or 2 segments),
making the generic IO path contain no allocations/frees for smaller IO.
Probably that would get us pretty close to rw_page. For direct/sync IO,
we'll go direct to ->queue_rq mostly, too.
The downside I see is that this is an OOB IO path. Once we start adding
IO scheduling for those that need that, then this will completely bypass
that.
--
Jens Axboe
next prev parent reply other threads:[~2014-11-14 1:29 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-14 0:05 [PATCH] NVMe: Add rw_page support Keith Busch
2014-11-14 1:29 ` Jens Axboe [this message]
2014-11-14 14:58 ` Matthew Wilcox
2014-11-14 15:07 ` Jens Axboe
2014-11-14 15:52 ` Matthew Wilcox
2014-11-14 16:32 ` Jens Axboe
2014-11-14 17:05 ` Keith Busch
2014-11-14 20:53 ` Jens Axboe
2014-11-14 22:59 ` Keith Busch
2014-11-14 14:55 ` Matthew Wilcox
[not found] ` <CANvN+ekQTdNgPe33iaM_9=2Hjrfds2B2R3d3XK06K9n=SY+ZKA@mail.gmail.com>
2014-11-14 22:50 ` Keith Busch
2014-11-14 22:56 ` Jens Axboe
2014-11-14 23:04 ` Keith Busch
2014-11-14 23:30 ` Jens Axboe
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=54655B01.9090206@kernel.dk \
--to=axboe@kernel.dk \
/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