3 ms·
That depends on how you access them. If you only ever iterate over all files readdir(3) in a tight loop is as fast as it can get; but if you need lots of access
by jlg23 8y ago
That depends on how you access them. If you only ever iterate over all files readdir(3) in a tight loop is as fast as it can get; but if you need lots of access to specific files, you will waste a lot of time reading directory entries just to discard them...
If there is even a remote chance you will use standard Unix tools on your files as well, I'd go for the subdirectories.