From 02c3dc9de8d3cf26b319b7a7b144878a2afb91bb Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Fri, 6 Mar 2009 10:27:43 +0100 Subject: cat: use larger buffer sizes to reduce read/write-syscall overhead * src/cat.c (max): Remove definition. Use MAX from system.h instead. (compute_buffer_size): New function to compute the input and output buffer sizes, which are now set at 8 times st_blksize with a maximum of 32KiB. Previously the typical block sizes used were 1KiB for pipes and 4KiB for files, and now will be 8KiB and 32KiB respectively. (main): Use it. This change can double throughput on modern systems. For timings, see http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/16040 Suggestion from Tzvi Rotshtein. --- THANKS | 1 + 1 file changed, 1 insertion(+) (limited to 'THANKS') diff --git a/THANKS b/THANKS index e8c7b5cd1..c4e900b12 100644 --- a/THANKS +++ b/THANKS @@ -553,6 +553,7 @@ Torbjorn Granlund tege@nada.kth.se Torbjorn Lindgren tl@funcom.no Torsten Landschoff torsten@pclab.ifg.uni-kiel.de Tristan Miller psychonaut@nothingisreal.com +Tzvi Rotshtein tzvi.ro@gmail.com Ulrich Drepper drepper@gnu.org Ulrich Hermisson ulrich_hermisson@hotmail.com Urs Thuermann urs@isnogud.escape.de -- cgit v1.2.3-70-g09d2