For a directory containing 10k files, it takes several seconds for the function in `directory-files` execute.