I'm using I need to load data in some files on a windows network share (samba), mounted on OSX. When listing the relevant directory in a shell, the performance is acceptable:
% time ls $DIR|wc -w
26542
ls -G $DIR 0.05s user 0.33s system 98% cpu 0.376 total
wc -w 0.00s user 0.00s system 1% cpu 0.376 total
Compared to MMA:
In[36]:= fn = FileNames[All, dir]; // AbsoluteTiming
Out[33]= {30.8174, Null}
Compared to local MMA (for the same dir):
In[36]:= fn = FileNames[All, dir]; // AbsoluteTiming
Out[33]= {0.206, Null}
Edit
It seems that MMA is making an excessive amount of system calls since when listing the share mounted on (Windows 10) localhost is still very slow, though much faster:
In[36]:= fn = FileNames[All, dir]; // AbsoluteTiming
Out[33]= {2.502, Null}