[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130331212354.GA5240@dcvr.yhbt.net>
Date: Sun, 31 Mar 2013 21:23:54 +0000
From: Eric Wong <normalperson@...t.net>
To: Pavel Machek <pavel@....cz>
Cc: "Myklebust, Trond" <Trond.Myklebust@...app.com>,
Zach Brown <zab@...hat.com>,
Paolo Bonzini <pbonzini@...hat.com>,
Ric Wheeler <rwheeler@...hat.com>,
Linux FS Devel <linux-fsdevel@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"Chris L. Mason" <clmason@...ionio.com>,
Christoph Hellwig <hch@...radead.org>,
Alexander Viro <aviro@...hat.com>,
"Martin K. Petersen" <mkp@....net>, Hannes Reinecke <hare@...e.de>,
Joel Becker <jlbec@...lplan.org>
Subject: Re: New copyfile system call - discuss before LSF?
Pavel Machek <pavel@....cz> wrote:
> Eric Wong wrote:
> > [1] my splice() annoyances:
> > * need to create/manage a pipe
> > * copy size limited by pipe size
> > * doesn't reduce userspace syscalls (just data copy overhead)
> > * easy to misuse and starve with blocking sockets + big buffers
> > * not many users, so bugs creep in (v3.7.8 was the first usable
> > version of the 3.7 series for TCP sockets)
>
> Could library be created to make it less annoying to use, and harder
> to misuse?
Maybe, but getting people to use the library would be the hard, too.
And a library would not reduce syscalls in the common case.
We already have current->splice_pipe for sendfile, so maybe splice can
be taught to transparently use that when neither FD is a pipe.
I also think a SPLICE_F_DONTWAIT flag might be necessary. It would be a
superset of SPLICE_F_NONBLOCK, but also act like MSG_DONTWAIT for the
non-pipe socket.
> splice man page does not mention pipe size limit...
It probably should. I think I discovered it by using it many years ago
and burned it into my mind.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists