Re: [hackers] [PATCH 1/2] Use *at functions with appropriate flags instead of lstat/lchown

From: Michael Forney <mforney_AT_mforney.org>
Date: Sat, 28 Dec 2019 16:06:20 -0800

On 2019-12-23, Laslo Hunhold <dev_AT_frign.de> wrote:
> What is the performance effect of this patch on big directories? It
> should be noticeable, shouldn't it?

There is a slight performance benefit, but it is pretty negligible due
to system call overhead. I tested du(1) on an extracted linux-5.4.6
source tree and saw an improvement of about 4-5% on my system
(comparing average of 20 runs).

I think the main benefit is the decreased stack usage and the
possibility to refactor other tools like cp to share the recurse code
(since now the base name is passed by itself).
Received on Sun Dec 29 2019 - 01:06:20 CET

This archive was generated by hypermail 2.3.0 : Sun Dec 29 2019 - 01:12:22 CET