sendfile(2) SF_NOPUSH flag proposal

Terry Lambert tlambert2 at mindspring.com
Wed May 28 22:31:15 PDT 2003


Igor Sysoev wrote:
> No, I do want these flags because they resolve the problem of partially
> filled packets.  I believe that this problem can be solved without a fixing
> the sendfile() implementation.

By kludging it, you mean.

> The portability argument is bogus because sendfile() portability is nonsense.

Darwin has sendfile.  See the released source code: it matches
the FreeBSD semantics, from what I can tell.


> The drawback that really annoyed me is that sendfile() blocks on a reading
> from a disk while a sending to non-blocking socket.  Although I see three
> workarounds it's much better to fix this inside sendfile().

There's no workaround for the latency issue, which comes from
the fact that a trap handles the request for more pages, and
that blocks all callers.  Threads has the same problem in libc_r.

> Five people ?

Bill Fenner, Matt Dillon, Peter Jeremy, Marc Slemko, Terry Lambert,
Garance Droshin.

> > Other than writing the correct code for you, there's little
> > else we can do, and I, at least, have other code I need to
> > write, to solve my own problems.
> 
> Well, Terry, write your code and I will write my own.

Fine.  Just don't ask us to run it.

-- Terry


More information about the freebsd-arch mailing list