Ivan Korotkov wrote:
> this is an enhancement proposal to use sendfile instead of read/write loop
> in cp(1) on Linux 2.6.33 and above to speed up copying. WDYT?

The feature is very new.  It think it is too new to use in a coreutils
command like cp.  For anyone who uses a single binary on multiple
different kernels (not that uncommon) this could cause the program to
use the new sendfile(2) api on the older kernel which does not support
it causing pain to those users.  In order to use it the program would
need to dynamically determine at runtime if the feature was available
and only use it then.  That adds too much complexity for a simple
program like cp should be.

Do you have any benchmarks which would show what type of performance
improvement can be expected of a change from read(2)-write(2) to
sendfile(2) between descriptors?  Benchmark data would be most useful
in determining the worth of such feature changes.

Bob


Reply via email to