stream: refactor Writable buffering
Another try on this, now without the reduced performance:
streams/writable-manywrites.js callback='no' writev='no' sync='no' n=2000000 *** 8.49 % ±1.42% ±1.88% ±2.42%
streams/writable-manywrites.js callback='no' writev='no' sync='yes' n=2000000 0.28 % ±1.38% ±1.84% ±2.40%
streams/writable-manywrites.js callback='no' writev='yes' sync='no' n=2000000 *** 36.63 % ±3.10% ±4.09% ±5.28%
streams/writable-manywrites.js callback='no' writev='yes' sync='yes' n=2000000 -0.72 % ±2.57% ±3.42% ±4.46%
streams/writable-manywrites.js callback='yes' writev='no' sync='no' n=2000000 *** 6.75 % ±1.16% ±1.54% ±1.99%
streams/writable-manywrites.js callback='yes' writev='no' sync='yes' n=2000000 -0.67 % ±1.86% ±2.48% ±3.23%
streams/writable-manywrites.js callback='yes' writev='yes' sync='no' n=2000000 *** 10.91 % ±1.75% ±2.33% ±3.02%
streams/writable-manywrites.js callback='yes' writev='yes' sync='yes' n=2000000 -1.70 % ±2.71% ±3.61% ±4.70%
Benchmarks from https://github.com/nodejs/node/pull/31066
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines