On Fri, Oct 29, 2010 at 06:16:32PM +0200, Andreas Schwab wrote:
>From coreutils/src/ls.c:
/* Note has_capability() adds around 30% runtime to `ls --color` */
Andreas.
I think that's something we can live with. Colorizing is already significant
overhead, and if performance is important, don't do it:
/usr$ time ls --color=yes -R > /dev/null
real 0m23.871s
user 0m1.315s
sys 0m22.513s
/usr$ time ls --color=no -R > /dev/null
real 0m3.707s
user 0m0.636s
sys 0m3.060s
(Actually average of three runs, after discarding one.)
--
Matthew Miller <mattdm(a)mattdm.org>
Senior Systems Architect -- Instructional & Research Computing Services
Harvard School of Engineering & Applied Sciences