Chenyu Yang
212a9724d5
benchmark: add undici websocket benchmark
...
Refs: https://github.com/nodejs/performance/issues/114
PR-URL: https://github.com/nodejs/node/pull/50586
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com >
2023-12-06 20:05:38 +00:00
Michael Dawson
abd8ff6f78
benchmark: skip test-benchmark-os on IBMi
...
- IBMi does not have the os.uptime implemented so skip
otherwise CI tests fail.
Signed-off-by: Michael Dawson <midawson@redhat.com >
PR-URL: https://github.com/nodejs/node/pull/50286
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br >
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2023-10-23 21:27:55 -04:00
Aras Abbasi
a58ffad656
lib: improve performance of validateStringArray and validateBooleanArray
...
PR-URL: https://github.com/nodejs/node/pull/49756
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2023-10-22 21:12:38 +00:00
Abdirahim Musse
286fdafe9d
test: skip test-benchmark-os.js on IBM i
...
PR-URL: https://github.com/nodejs/node/pull/50208
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Michael Dawson <midawson@redhat.com >
2023-10-18 15:33:56 -04:00
Aras Abbasi
54bb691c0b
util: lazy parse mime parameters
...
PR-URL: https://github.com/nodejs/node/pull/49889
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
2023-10-08 15:43:16 +00:00
Vinicius Lourenço
952cf0d17a
lib: reduce overhead of validateObject
...
PR-URL: https://github.com/nodejs/node/pull/49928
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
2023-10-02 12:56:39 +00:00
Yagiz Nizipli
ead407915e
url: drop ICU requirement for parsing hostnames
...
PR-URL: https://github.com/nodejs/node/pull/47339
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2023-04-05 09:05:29 -07:00
Yagiz Nizipli
c4581abff6
url: replace url-parser with ada
...
PR-URL: https://github.com/nodejs/node/pull/46410
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com >
Reviewed-By: Robert Nagy <ronagy@icloud.com >
2023-02-06 19:21:39 +00:00
Rafael Gonzaga
70d269de77
benchmark: include webstreams benchmark
...
Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com >
PR-URL: https://github.com/nodejs/node/pull/45876
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com >
Reviewed-By: Paolo Insogna <paolo@cowtech.it >
2022-12-21 16:09:43 +00:00
Thiago Oliveira Santos
0f3e531096
lib: performance improvement on readline async iterator
...
Using a direct approach to create the readline async iterator
allowed an iteration over 20 to 58% faster.
**BREAKING CHANGE**: With that change, the async iteterator
obtained from the readline interface doesn't have the
property "stream" any longer. This happened because it's no
longer created through a Readable, instead, the async
iterator is created directly from the events of the readline
interface instance, so, if anyone is using that property,
this change will break their code.
Also, the Readable added a backpressure control that is
fairly compensated by the use of FixedQueue + monitoring
its size. This control wasn't really precise with readline
before, though, because it only pauses the reading of the
original stream, but the lines generated from the last
message received from it was still emitted. For example:
if the readable was paused at 1000 messages but the last one
received generated 10k lines, but no further messages were
emitted again until the queue was lower than the readable
highWaterMark. A similar behavior still happens with the
new implementation, but the highWaterMark used is fixed: 1024,
and the original stream is resumed again only after the queue
is cleared.
Before making that change, I created a package implementing
the same concept used here to validate it. You can find it
[here](https://github.com/Farenheith/faster-readline-iterator )
if this helps anyhow.
PR-URL: https://github.com/nodejs/node/pull/41276
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2022-10-24 12:49:16 +00:00
Yagiz Nizipli
6adaf23c20
benchmark: add blob benchmark
...
PR-URL: https://github.com/nodejs/node/pull/44990
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2022-10-17 12:00:31 +00:00
Daniel Bevenius
9bc16e6a6f
Revert "test: skip tests for openssl-3.0.0-alpha15"
...
This reverts commit 2ff93c8975 .
PR-URL: https://github.com/nodejs/node/pull/39437
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2021-07-21 14:10:37 +02:00
Daniel Bevenius
2ff93c8975
test: skip tests for openssl-3.0.0-alpha15
...
This commit skips some test when OpenSSL 3.0.0-alpha15 is used as there
is an issue that causes them to fail.
This is only a temp solution until there is new OpenSSL release.
Fixes: https://github.com/nodejs/node/issues/38373
PR-URL: https://github.com/nodejs/node/pull/38451
Reviewed-By: Richard Lau <rlau@redhat.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2021-05-06 10:19:11 -04:00
Rich Trott
baa9e65214
test: remove skip for fixed test-benchmark-fs
...
PR-URL: https://github.com/nodejs/node/pull/37803
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2021-03-21 08:26:14 -07:00
Guy Bedford
f3ce2811dd
module: use Wasm CJS lexer when available
...
PR-URL: https://github.com/nodejs/node/pull/35583
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Geoffrey Booth <webmaster@geoffreybooth.com >
2020-10-12 04:24:41 -07:00
Rich Trott
31ba9a20bd
test: run test-benchmark-napi on arm
...
Necessary Makefile changes have happened. This now passes in CI.
PR-URL: https://github.com/nodejs/node/pull/34502
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2020-07-25 22:05:15 -07:00
Bradley Farias
66810a0d47
policy: add startup benchmark and make SRI lazier
...
PR-URL: https://github.com/nodejs/node/pull/29527
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2020-07-14 13:03:04 -05:00
Rich Trott
c7627da837
build: add benchmark tests to CI runs
...
Closes: https://github.com/nodejs/node/issues/34321
PR-URL: https://github.com/nodejs/node/pull/34288
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matheus Marchini <mat@mmarchini.me >
2020-07-13 22:17:00 -07:00
Ruben Bridgewater
9e40df763b
test: refactor all benchmark tests to use the new test option
...
This reverts commit aa0a01bd36 .
PR-URL: https://github.com/nodejs/node/pull/31755
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2020-03-09 22:35:54 +01:00
Brian White
5cc0754090
benchmark: remove problematic tls params
...
These very small values can cause crashes/exceptions to occur on some
systems because most time is spent in V8 GC or in parts of node core
that are not being tested (e.g. streams).
PR-URL: https://github.com/nodejs/node/pull/31816
Reviewed-By: James M Snell <jasnell@gmail.com >
2020-03-05 23:41:56 -05:00
Matteo Collina and Stephen Belanger
9fdb6e6aaf
async_hooks: add executionAsyncResource
...
Remove the need for the destroy hook in the basic APM case.
Co-authored-by: Stephen Belanger <admin@stephenbelanger.com >
PR-URL: https://github.com/nodejs/node/pull/30959
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com >
Reviewed-By: Chengzhong Wu <legendecas@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2020-02-11 20:59:09 +01:00
Anna Henningsen
aa0a01bd36
Revert "test: refactor all benchmark tests to use the new test option"
...
This reverts commit 78aa348f4e .
Refs: https://github.com/nodejs/node/pull/31396
PR-URL: https://github.com/nodejs/node/pull/31722
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gus Caplan <me@gus.host >
Reviewed-By: Vladimir de Turckheim <vlad2t@hotmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2020-02-10 22:35:33 +01:00
Ruben Bridgewater
78aa348f4e
test: refactor all benchmark tests to use the new test option
...
PR-URL: https://github.com/nodejs/node/pull/31396
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2020-02-09 13:31:54 +01:00
Rich Trott
8a14884bab
test: fix test-benchmark-http
...
fe3975783c added a setting to a benchmark
which needs to be reflected in the test.
PR-URL: https://github.com/nodejs/node/pull/31686
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
2020-02-07 16:48:59 -10:00
Rich Trott
5cf789e554
test,benchmark: fix test-benchmark-zlib
...
PR-URL: https://github.com/nodejs/node/pull/31538
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2020-01-29 19:16:16 -08:00
Brian White
2170259940
buffer: improve concat() performance
...
PR-URL: https://github.com/nodejs/node/pull/31522
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2020-01-28 19:57:20 -08:00
Brian White
59a1981a22
crypto: improve randomBytes() performance
...
PR-URL: https://github.com/nodejs/node/pull/31519
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2020-01-28 06:56:16 -08:00
Brian White
886965963a
deps: switch to chromium's zlib implementation
...
This implementation provides optimizations not included upstream.
PR-URL: https://github.com/nodejs/node/pull/31201
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
2020-01-26 18:47:02 -05:00
legendecas
bf7265ffc6
benchmark: add benchmark on async_hooks enabled http server
...
PR-URL: https://github.com/nodejs/node/pull/31100
Refs: https://github.com/nodejs/diagnostics/issues/124
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
2020-01-02 17:51:19 +01:00
Robert Nagy
f68285b098
benchmark: include writev in benchmark
...
Currently we only consider write when benchmarking.
PR-URL: https://github.com/nodejs/node/pull/31066
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-12-25 23:45:49 +01:00
Ruben Bridgewater
bdb1083ef5
benchmark: add more util inspect and format benchmarks
...
This adds a couple of benchmarks to check different options and code
paths.
PR-URL: https://github.com/nodejs/node/pull/30767
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Denys Otrishko <shishugi@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-12-07 00:38:27 +01:00
Rich Trott
cf3a05ae5f
test: fix test-benchmark-streams
...
test-benchmark-streams is currently failing because the `sync` option is
not specified in the test, resulting in too many benchmarks running.
PR-URL: https://github.com/nodejs/node/pull/30757
Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2019-12-02 06:03:50 -08:00
dnlup
864608ec66
test: use spread instead of Object.assign
...
PR-URL: https://github.com/nodejs/node/pull/30419
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
2019-11-25 08:58:40 +05:30
Rich Trott
acd35d9275
test: fix test-benchmark-cluster
...
test-benchmark-cluster needs to account for an option added in 973f324 .
PR-URL: https://github.com/nodejs/node/pull/30342
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-11-09 14:11:06 -08:00
Anna Henningsen
b35181f877
fs: add bufferSize option to fs.opendir()
...
Add an option that controls the size of the internal
buffer.
Fixes: https://github.com/nodejs/node/issues/29941
PR-URL: https://github.com/nodejs/node/pull/30114
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-10-28 14:34:25 +01:00
Rich Trott
7991b57cfd
test: fix fs benchmark test
...
Add missing option "mode". Alphabetize options for easier maintenance.
PR-URL: https://github.com/nodejs/node/pull/29967
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: David Carlier <devnexen@gmail.com >
2019-10-14 07:53:51 -07:00
Anna Henningsen
82ebcb37d6
benchmark: improve process.env benchmarks
...
Benchmark different types of operations and make results comparable
by normalizing process.env for enumeartion.
PR-URL: https://github.com/nodejs/node/pull/29188
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-09-18 23:24:42 +02:00
Rich Trott
167960f3ca
test: fix test-benchmark-net
...
Fix test-benchmark-net to accommodate recent benchmark additions.
PR-URL: https://github.com/nodejs/node/pull/29359
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-08-28 09:48:27 -07:00
Brian White
f0c8898fb5
buffer: improve equals() performance
...
PR-URL: https://github.com/nodejs/node/pull/29199
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2019-08-21 21:42:21 -07:00
Rich Trott
b9ff6a3fb1
test: add required settings to test-benchmark-buffer
...
A benchmark was added but the appropriate settings were not added to
test-benchmark-buffer. These two additions make sure that the new
benchmark file only runs a single benchmark during testing.
PR-URL: https://github.com/nodejs/node/pull/29163
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com >
2019-08-16 10:15:38 -07:00
João Reis
0376b5b7ba
benchmark: use test/common/tmpdir consistently
...
Many benchmarks use test/common/tmpdir. This changes 3 benchmarks that
use NODE_TMPDIR to also use test/common/tmpdir.
This is necessary in preparation for the next commit that changes tmpdir
to delete tmpdir.path when the Node.js process exits. Thus, if multiple
benchmarks are run sequentially, the ones that use tmpdir will remove
the directory and the ones changed here would fail because it does not
exist. This happens when running test/benchmark.
Note: to explicitly select a directory for tmpdir, use NODE_TEST_DIR.
PR-URL: https://github.com/nodejs/node/pull/28858
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-08-10 19:21:35 -07:00
Joyee Cheung
c5817abff5
benchmark: add benchmark for node -p
...
PR-URL: https://github.com/nodejs/node/pull/27320
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-04-28 14:46:27 +08:00
Rich Trott
d5bb500d0f
test: fix test-benchmark-buffer
...
Using `len=2` in test-benchmark-buffer was resulting in a `RangeError`
in buffer-base64-encode.js. Change to `len=256` which works in all
buffer benchmarks.
PR-URL: https://github.com/nodejs/node/pull/27260
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
2019-04-18 10:25:59 -07:00
Rich Trott
c86883cfac
test: fix test-benchmark-module
...
A recent commit broke test-benchmark-module. This fixes it.
PR-URL: https://github.com/nodejs/node/pull/27094
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Bryan English <bryan@bryanenglish.com >
2019-04-04 22:13:56 -07:00
Refael Ackermann
c7b6a22f1a
benchmark,test: refactoring
...
PR-URL: https://github.com/nodejs/node/pull/26119
Refs: https://github.com/nodejs/node/pull/26101
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
2019-02-18 13:15:28 -05:00
Refael Ackermann
fe58bef7e2
test: add arg to narrow http benchmark test
...
PR-URL: https://github.com/nodejs/node/pull/26101
Reviewed-By: Weijia Wang <starkwang@126.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2019-02-14 19:09:36 -05:00
Rich Trott
6f27f5350c
test: fix test-benchmark-zlib
...
The addition of brotli to zlib benchmarks means that test-benchmark-zlib
needs to be modified. This is that modification.
PR-URL: https://github.com/nodejs/node/pull/25365
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2019-01-06 15:41:13 -08:00
Joyee Cheung
8450d11292
benchmark: support URL inputs in create-clientrequest
...
This patch adds the option in the create-clientrequest benchmark
to accept URL inputs (as strings or as URL objects) so we can
measure the impact of URL parsing in a more sophisticated use case.
PR-URL: https://github.com/nodejs/node/pull/24302
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-20 05:14:36 +08:00
Joyee Cheung
a365bb9cb1
benchmark: pre-generate data set for URL benchmarks
...
This patch:
- Introduces `common.bakeUrlData` which can be used to pre-generate
the data set for the URL benchmarks to loop through instead of
looping over a constant.
- Add the option to use WPT data in benchmarks for better diversity
in the input
- Add the option to benchmark URL parsing with base URLs (whatwg only)
- Moves the data in `benchmark/fixtures/url-inputs.js` to
`benchmark/common.js`
PR-URL: https://github.com/nodejs/node/pull/24302
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-20 05:14:34 +08:00
Rich Trott
b5420c9577
test: move benchmark tests out of main test suite
...
Move benchmark tests (which are slow) out of the main test suite. We can
hopefully add them to node-daily-master so that they are still run daily
on CI.
PR-URL: https://github.com/nodejs/node/pull/24265
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-11-10 22:44:26 -08:00