Re: [PATCH V2] get_maintainer: Prepare for separate MAINTAINERS files

From: Joe Perches
Date: Wed Aug 02 2017 - 16:35:57 EST


On Wed, 2017-08-02 at 11:15 -0700, Linus Torvalds wrote:
> On Wed, Aug 2, 2017 at 11:06 AM, Randy Dunlap <rdunlap@xxxxxxxxxxxxx> wrote:
> >
> > IMO, the parse-maintainters.pl (sorting) script makes the need for separate
> > MAINTAINERS files much less important since the file can be "fixed" easily
> > at any time.
>
> For me it's not the "fixing". It's the inevitable merge mess, and the
> two hundred commits that I have to go through.
>
> That said, the extra time just to look for MAINTAINERS files makes me
> unhappy. It may be just .3s on Joe's machine, but it's presumably much
> more when things aren't in the filesystem caches. I (like apparently
> Joe) have an SSD so it's not a big deal for me, but..
>
> Just having a single MAINTAINERS directory would alleviate that concern.

Yeah. Quite a bit. With an i5-6200 and an SSD:

Looking for all MAINTAINERS files:

Cold cache find:

$ time find . -not \( -path ./.git -prune \) -name MAINTAINERS
./drivers/staging/unisys/MAINTAINERS
./MAINTAINERS

real 0m3.129s
user 0m0.368s
sys 0m0.828s

Warm cache find:

$ time find . -not \( -path ./.git -prune \) -name MAINTAINERS
./drivers/staging/unisys/MAINTAINERS
./MAINTAINERS

real 0m0.151s
user 0m0.084s
sys 0m0.064s

vs looking for all files in MAINTAINERS directory

Cold cache:

$ time find MAINTAINERS.tmp/ | wc -l
1736

real 0m0.037s
user 0m0.016s
sys 0m0.012s

Warm cache:

$ time find MAINTAINERS.tmp/ | wc -l
1736

real 0m0.017s
user 0m0.012s
sys 0m0.008s