sahlberg / libnfs

NFS client library
Other
524 stars 201 forks source link

Write multiple pdus at once. #414

Closed dgaleano-ilm closed 1 year ago

dgaleano-ilm commented 1 year ago

Attempt to batch the iovectors from several pdus in order to reduce the number of calls to writev. In the best case this change will reduce the number of calls to writev to an eighth of what they were before.

The maximum number of vectors was reduced to match the limit set on the Linux kernel for the fast code path that handles iovectors.

dgaleano-ilm commented 1 year ago

The existing code is using a mixture of tabs and spaces so I was not sure what to use but the code I replaced in particular was using more spaces than tabs so I went with spaces. Please let me know if you prefer tabs.

sahlberg commented 1 year ago

Merged, thanks.