MEDIUM: buffers: make b_xfer() automatically swap buffers when possible

Whenever it's possible to avoid a copy, b_xfer() will simply swap the
buffer's heads without touching the data. This has brought the performance
back from 140 kH/s to 202 kH/s on the test case.
1 file changed