| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
Need a signature for first commit message. |
Sorry, something went wrong.
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #64431 +/- ##
==========================================
- Coverage 90.24% 90.23% -0.01%
==========================================
Files 741 741
Lines 241384 241391 +7
Branches 45480 45487 +7
==========================================
- Hits 217844 217827 -17
- Misses 15097 15129 +32
+ Partials 8443 8435 -8
... and 40 files with indirect coverage changes 🚀 New features to boost your workflow:
|
Sorry, something went wrong.
The [[queue]] backing the controllers became a ring buffer, but the read and write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift, which is O(n) and, even for the single pending request of the await-each regime, far slower than an indexed head advance. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read or write actually parks. pipe-to: +4.7% to +9.4% (all 16 configs, ***) readable-read type=byob: +2.3% (**) parked read loop: +15%, write loop: +11% (local harness) Follow-up to nodejs#64312. Signed-off-by: Matteo Collina <hello@matteocollina.com>
Sorry, something went wrong.
|
Benchmark GHA (webstreams): https://github.com/nodejs/node/actions/runs/29233460863 Results
Benchmark results: confidence improvement accuracy (*) (**) (***) webstreams/creation.js kind='ReadableStream.tee' n=50000 0.64 % ±6.98% ±9.19% ±11.80% webstreams/creation.js kind='ReadableStream' n=50000 0.75 % ±7.98% ±10.51% ±13.49% webstreams/creation.js kind='ReadableStreamBYOBReader' n=50000 3.30 % ±6.13% ±8.08% ±10.36% webstreams/creation.js kind='ReadableStreamDefaultReader' n=50000 1.63 % ±7.61% ±10.03% ±12.86% webstreams/creation.js kind='TransformStream' n=50000 -0.51 % ±7.00% ±9.23% ±11.84% webstreams/creation.js kind='WritableStream' n=50000 -0.63 % ±7.84% ±10.33% ±13.26% webstreams/js_transfer.js n=10000 payload='ReadableStream' -0.43 % ±9.64% ±12.71% ±16.30% webstreams/js_transfer.js n=10000 payload='TransformStream' 0.77 % ±9.28% ±12.23% ±15.70% webstreams/js_transfer.js n=10000 payload='WritableStream' 0.83 % ±9.45% ±12.46% ±15.98% webstreams/pipe-to.js highWaterMarkW=1024 highWaterMarkR=1024 n=500000 * 7.38 % ±7.34% ±9.68% ±12.42% webstreams/pipe-to.js highWaterMarkW=1024 highWaterMarkR=2048 n=500000 * 8.21 % ±7.21% ±9.51% ±12.20% webstreams/pipe-to.js highWaterMarkW=1024 highWaterMarkR=4096 n=500000 * 7.71 % ±7.29% ±9.61% ±12.33% webstreams/pipe-to.js highWaterMarkW=1024 highWaterMarkR=512 n=500000 7.03 % ±7.25% ±9.56% ±12.27% webstreams/pipe-to.js highWaterMarkW=2048 highWaterMarkR=1024 n=500000 * 7.39 % ±7.26% ±9.57% ±12.28% webstreams/pipe-to.js highWaterMarkW=2048 highWaterMarkR=2048 n=500000 * 8.57 % ±7.26% ±9.57% ±12.28% webstreams/pipe-to.js highWaterMarkW=2048 highWaterMarkR=4096 n=500000 * 7.49 % ±7.15% ±9.43% ±12.10% webstreams/pipe-to.js highWaterMarkW=2048 highWaterMarkR=512 n=500000 * 7.74 % ±7.29% ±9.61% ±12.33% webstreams/pipe-to.js highWaterMarkW=4096 highWaterMarkR=1024 n=500000 * 7.58 % ±7.30% ±9.62% ±12.35% webstreams/pipe-to.js highWaterMarkW=4096 highWaterMarkR=2048 n=500000 * 9.04 % ±7.43% ±9.80% ±12.57% webstreams/pipe-to.js highWaterMarkW=4096 highWaterMarkR=4096 n=500000 * 9.27 % ±7.45% ±9.82% ±12.61% webstreams/pipe-to.js highWaterMarkW=4096 highWaterMarkR=512 n=500000 * 8.51 % ±7.42% ±9.78% ±12.55% webstreams/pipe-to.js highWaterMarkW=512 highWaterMarkR=1024 n=500000 * 7.52 % ±7.21% ±9.51% ±12.20% webstreams/pipe-to.js highWaterMarkW=512 highWaterMarkR=2048 n=500000 * 8.04 % ±7.35% ±9.68% ±12.42% webstreams/pipe-to.js highWaterMarkW=512 highWaterMarkR=4096 n=500000 * 8.19 % ±7.32% ±9.64% ±12.38% webstreams/pipe-to.js highWaterMarkW=512 highWaterMarkR=512 n=500000 6.34 % ±7.18% ±9.46% ±12.14% webstreams/readable-async-iterator.js type='bytes' n=100000 4.92 % ±9.89% ±13.04% ±16.73% webstreams/readable-async-iterator.js type='normal' n=100000 0.64 % ±7.19% ±9.47% ±12.15% webstreams/readable-read-buffered.js bufferSize=1 n=100000 -0.84 % ±6.44% ±8.48% ±10.89% webstreams/readable-read-buffered.js bufferSize=10 n=100000 -0.49 % ±5.97% ±7.87% ±10.10% webstreams/readable-read-buffered.js bufferSize=100 n=100000 -1.56 % ±6.02% ±7.94% ±10.18% webstreams/readable-read-buffered.js bufferSize=1000 n=100000 -0.08 % ±6.24% ±8.23% ±10.56% webstreams/readable-read.js type='byob' n=100000 0.48 % ±7.52% ±9.91% ±12.72% webstreams/readable-read.js type='normal' n=100000 ** 7.82 % ±5.83% ±7.69% ±9.87% Be aware that when doing many comparisons the risk of a false-positive result increases. In this case, there are 33 comparisons, you can thus expect the following amount of false-positive results: 1.65 false positives, when considering a 5% risk acceptance (*, **, ***), 0.33 false positives, when considering a 1% risk acceptance (**, ***), 0.03 false positives, when considering a 0.1% risk acceptance (***)
|
Sorry, something went wrong.
The [[queue]] backing the controllers became a ring buffer, but the read and write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift, which is O(n) and, even for the single pending request of the await-each regime, far slower than an indexed head advance. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read or write actually parks. pipe-to: +4.7% to +9.4% (all 16 configs, ***) readable-read type=byob: +2.3% (**) parked read loop: +15%, write loop: +11% (local harness) Follow-up to #64312. Signed-off-by: Matteo Collina <hello@matteocollina.com> PR-URL: #64431 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
The [[queue]] backing the controllers became a ring buffer, but the read and write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift, which is O(n) and, even for the single pending request of the await-each regime, far slower than an indexed head advance. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read or write actually parks. pipe-to: +4.7% to +9.4% (all 16 configs, ***) readable-read type=byob: +2.3% (**) parked read loop: +15%, write loop: +11% (local harness) Follow-up to #64312. Signed-off-by: Matteo Collina <hello@matteocollina.com> PR-URL: #64431 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
The [[queue]] backing the controllers became a ring buffer, but the read and write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift, which is O(n) and, even for the single pending request of the await-each regime, far slower than an indexed head advance. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read or write actually parks. pipe-to: +4.7% to +9.4% (all 16 configs, ***) readable-read type=byob: +2.3% (**) parked read loop: +15%, write loop: +11% (local harness) Follow-up to #64312. Signed-off-by: Matteo Collina <hello@matteocollina.com> PR-URL: #64431 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
The [[queue]] backing the controllers became a ring buffer, but the read and write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift, which is O(n) and, even for the single pending request of the await-each regime, far slower than an indexed head advance. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read or write actually parks. pipe-to: +4.7% to +9.4% (all 16 configs, ***) readable-read type=byob: +2.3% (**) parked read loop: +15%, write loop: +11% (local harness) Follow-up to #64312. Signed-off-by: Matteo Collina <hello@matteocollina.com> PR-URL: #64431 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
| Back | FazBrowse Home | New Git URL |
The [[queue]] backing the controllers is now a ring buffer, but the read/write request queues (readRequests, readIntoRequests, writeRequests) were left as plain arrays consumed with ArrayPrototypeShift. Back them with the same Queue, materialized lazily from the shared empty queue so acquiring a reader or constructing a writer allocates no request storage until a read/write parks.
Follow-up to #64312.