From: Jeff Garzik <jeff@garzik.org>
To: Steven Dake <sdake@redhat.com>
Cc: hail-devel@vger.kernel.org
Subject: Re: [PATCH 1/3 v2] chunkd: remove sendfile(2) zero-copy support
Date: Sun, 18 Jul 2010 19:10:09 -0400 [thread overview]
Message-ID: <4C4389D1.6000201@garzik.org> (raw)
In-Reply-To: <4C4278EA.8000605@redhat.com>
On 07/17/2010 11:45 PM, Steven Dake wrote:
> On 07/16/2010 10:46 PM, Jeff Garzik wrote:
>> chunkd: remove sendfile(2) zero-copy support
>>
>> chunkd will be soon checksumming data in main memory. That removes
>> the utility of a zero-copy interface which bypasses the on-heap
>> data requirement.
>>
>> Signed-off-by: Jeff Garzik<jgarzik@redhat.com>
> May be able to use vmsplice with sendfile (if linux is only target
> platform). Haven't tried it myself, but the operations look interesting
> at achieving zero copy with sockets from memory addresses.
Even though the man pages say "only for pipes", this syscall definitely
works with TCP. The big question: is it actually faster than
read()+write() ?
Years ago, I experimented with using some fancy new Linux-specific
syscalls in a from-scratch implementation of cp(1). It turned out that
read()+write() was faster than other methods.
That was file->file copying. It's probably worth investigating
vmsplice() for our file->checksum->TCP case, definitely.
Jeff
next prev parent reply other threads:[~2010-07-18 23:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-17 5:46 [PATCH 0/3 v2] chunkd on-disk checksumming Jeff Garzik
2010-07-17 5:46 ` [PATCH 1/3 v2] chunkd: remove sendfile(2) zero-copy support Jeff Garzik
2010-07-18 3:45 ` Steven Dake
2010-07-18 23:10 ` Jeff Garzik [this message]
2010-07-18 23:23 ` Jeff Garzik
2010-07-17 5:47 ` [PATCH 2/3 v2] chunkd: Add checksum table to on-disk format, one sum per 64k of data Jeff Garzik
2010-07-17 5:47 ` [PATCH 3/3 v2] [chunkd] match network buffer size to checksum buffer size (64k) Jeff Garzik
2010-07-18 7:09 ` [PATCH 4/4] chunkd checksums each block, as it is read from disk Jeff Garzik
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=4C4389D1.6000201@garzik.org \
--to=jeff@garzik.org \
--cc=hail-devel@vger.kernel.org \
--cc=sdake@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.