HomePhabricator

grep: reduce the cost of pathauditor checks when grepping working copy

Description

grep: reduce the cost of pathauditor checks when grepping working copy

Running time hg grep zxczxczxczxczxc -l on mozilla-central:

before:

real	0m20,000s
user	0m15,796s
sys	0m4,189s

after:

real	0m10,903s
user	0m8,964s
sys	0m1,916s

if vfs didn't call pathauditor at all:

real	0m7,781s
user	0m5,968s
sys	0m1,790s

Differential Revision: https://phab.mercurial-scm.org/D8582

Details