Flexible I/O Tester development
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Yigal Korman <yigal@plexistor.com>
Cc: fio@vger.kernel.org
Subject: Re: Questions about mmap ioengine
Date: Tue, 13 Jan 2015 22:08:22 -0700	[thread overview]
Message-ID: <20150114050816.GB18148@kernel.dk> (raw)
In-Reply-To: <CACTTzNY2MfpkqDoP3xYW7XDDUoQ23iy2u3AcujYrt37tFo5smA@mail.gmail.com>

On Wed, Jan 07 2015, Yigal Korman wrote:
> On Wed, Dec 17, 2014 at 10:56 PM, Yigal Korman <yigal@plexistor.com> wrote:
> > Hi,
> > I have a couple of questions regarding the mmap ioengine.
> >
> > One of the benefits of doing mmap() VS write() is bypassing the need
> > of an intermediate buffer.
> > Instead of preparing a buffer for write(), data can be written
> > directly to file with mmap().
> > I want to do some performance comparisons on this subject with fio on
> > different filesystems.
> > After reviewing the code a bit, I saw that the mmap ioengine is only
> > responsible for writing the data.
> > The buffer preparation is done in the common code the same way for all
> > ioengines.
> > Am I understanding this correctly?
> > Is there another way to circumvent the buffer filling and implement
> > writing data directly with mmap?
> 
> I didn't get any answers yet, can someone comment?
> I'll be glad to implement the appropriate behavior myself with some guidance.

Fio can't really do it any other way, if you want to track this as IO.
So it prepares the data contents in its regular IO buffers, then copies
it to the mmap'ed area (or vice versa, for a read). It'd be trivial to
simply have the IO buffer point at the appropriate mmap'ed region, but
then you'd lose any tracking of latencies, bandwidth, etc. In other
words, it would not provide a lot of value.

-- 
Jens Axboe



      reply	other threads:[~2015-01-14  5:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-17 20:56 Questions about mmap ioengine Yigal Korman
2015-01-07  7:28 ` Yigal Korman
2015-01-14  5:08   ` Jens Axboe [this message]

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=20150114050816.GB18148@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=fio@vger.kernel.org \
    --cc=yigal@plexistor.com \
    /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