4 ms·
Decompressing files from a single tar.gz into memory can very easily be faster than opening a very large number of small files.
by plorkyeran 5y ago
Decompressing files from a single tar.gz into memory can very easily be faster than opening a very large number of small files.
- mmis1000 5y agoDepends on iops. On system with high iops(ssd), the impact of file count is negligible. On system with low iops (hhd, nfs or wsl on windows dirs), it is a nightmare. I used to try to run npm install in an old project on /mnt/c/ on wsl1. And the install that takes 20~30 second normally end up took 20 minutes. Because /mnt/c/ under wsl has extremely low iops.
- alerighi 5y agoThe problem is that then you have to write them on disk, since node expects to find a directory named node_modules somewhere. And yes you can expand them in /tmp that is typically mounted on a tmpfs (but not on Windows), but still you have to pass trough some kind of filesystem.