mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bernd Petrovitsch <bernd@firmix.at>
To: Francis Moreau <francis.moro@gmail.com>
Cc: Jeff Garzik <jeff@garzik.org>,
	linux-kernel@vger.kernel.org, jens.axboe@oracle.com
Subject: Re: question about splice performance
Date: Mon, 26 May 2008 11:06:41 +0200	[thread overview]
Message-ID: <1211792801.2052.14.camel@tara.firmix.at> (raw)
In-Reply-To: <38b2ab8a0805260157k14d9a64dkeef48d230b978cf4@mail.gmail.com>

Hi!

On Mon, 2008-05-26 at 10:57 +0200, Francis Moreau wrote:
> On Sun, May 25, 2008 at 10:47 PM, Jeff Garzik <jeff@garzik.org> wrote:
> >
> > If you drop caches you are not measuring splice speed.
> >
> > Use ramfs for your tests (guarantees data is in cache) instead.
> 
> So it seems that the gain when using splice to copy a file into another file
> is very limited. Maybe that's the reason why cp is still using read/write...

To point it out one more time: If you copy from one file on a physical
harddisk (or more or less similar hardware) to another (with cold
caches), the bottleneck is most probably the harddisk.

splice() simply reduces the amount of copied data in the RAM - and that
is practically irrelevant if you read and write to and from harddisks.

So if you want to measure the savings of using splice() (instad of
read()/write(), etc.): Copy to and from RAM disks (and thus rule out the
slow hardware).

	Bernd
-- 
Firmix Software GmbH                   http://www.firmix.at/
mobil: +43 664 4416156                 fax: +43 1 7890849-55
          Embedded Linux Development and Services



      reply	other threads:[~2008-05-26  9:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-25 15:12 Francis Moreau
2008-05-25 15:40 ` Jan Engelhardt
2008-05-25 17:22 ` Sitsofe Wheeler
2008-05-25 20:47 ` Jeff Garzik
2008-05-26  8:57   ` Francis Moreau
2008-05-26  9:06     ` Bernd Petrovitsch [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=1211792801.2052.14.camel@tara.firmix.at \
    --to=bernd@firmix.at \
    --cc=francis.moro@gmail.com \
    --cc=jeff@garzik.org \
    --cc=jens.axboe@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®