There are a number of socket options that can greatly affect the performance of a TCP-based server like Samba.
The socket options that Samba uses are settable both on the command line with the -O option, or in the smb.conf file.
The socket options section of the smb.conf manual page describes how to set these and gives recommendations.
Getting the socket options correct can make a big difference to your performance, but getting them wrong can degrade it by just as much. The correct settings are very dependent on your local network.
The socket option TCP_NODELAY is the one that seems to make the biggest single difference for most networks. Many people report that adding socket options = TCP_NODELAY doubles the read performance of a Samba drive. The best explanation I have seen for this is that the Microsoft TCP/IP stack is slow in sending TCP ACKs.
There have been reports that setting socket options = SO_RCVBUF=8192 in smb.conf can seriously degrade Samba performance on the loopback adaptor (IP Addess 127.0.0.1). It is strongly recommended that before specifying any settings for socket options the effect first be quantitatively measured on the server being configured.