Re:Performance of nnn vs. ls
by zeroimpl on Tuesday May 07, 2019 @07:44PM
(#19854539)
I’m not surprised there are a bunch of optimizations which could be made to “ls”. On a related note, I once looked at source code for “rm” (specifically “rm -rf”) and was surprised how inefficient it seemed. Not sure if it has changed since, but it would stat files before deleting and do various permissions checks - things that could be accomplished by just letting the kernel try to do the delete and then checking the status code. That ought to be faster 99% of the time.
[ Parent
| on HN ]