sendfile(2) SF_NOPUSH flag proposal

Igor Sysoev is at rambler-co.ru
Tue May 27 04:25:33 PDT 2003


On Tue, 27 May 2003, Peter Jeremy wrote:

> 2) The new feature provides significant performance benefit.   In this
>    case, I believe the overhead of calling setsockopt(2) is negligible
>    so the performance gain would be negligible.

I think the calling setsockopt(TCP_NOPUSH, 1) syscall has huge overhead
as compared to several C operators inside sendfile(2).

The turing TF_NOPUSH off has almost the same overhead as
setsockopt(TCP_NOPUSH, 0) if you need to call tcp_output(tp) inside
sendfile(2) and has no overhead at all if you do not need to call it.

> At this stage, I would suggest that you need to do better than "the
> change is cheap" to justify adding this feature.  Can you quantify
> the performance benefits, or provide some other justification?

My point is not "the cheap change" but "the cheap overhead".


Igor Sysoev
http://sysoev.ru/en/



More information about the freebsd-arch mailing list