Commit Graph

1152 Commits

Author SHA1 Message Date
Rafael Gonzaga
7c0cc12f0b
benchmark: add --runs support to run.js
PR-URL: https://github.com/nodejs/node/pull/55158
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
2024-10-18 15:33:58 +00:00
Rafael Gonzaga
48b852a7f5
benchmark: adjust byte size for buffer-copy
PR-URL: https://github.com/nodejs/node/pull/55295
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-10-14 12:14:01 +00:00
Robert Nagy
488ce99d76
events: optimize EventTarget.addEventListener
PR-URL: https://github.com/nodejs/node/pull/55312
Fixes: https://github.com/nodejs/node/issues/55311
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2024-10-14 10:24:32 +00:00
Rafael Gonzaga
aeadaba03f
benchmark: adjust config for deepEqual object
This should make easier to read on benchmark/compare
and when generating graphs

PR-URL: https://github.com/nodejs/node/pull/55254
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
2024-10-11 18:26:42 +00:00
Joyee Cheung
4eeeab09f0
benchmark: rewrite detect-esm-syntax benchmark
Syntax detection has been unflagged so it's no longer meaningful
to toggle the detection based on CLI flags. It was also previously
benchmarking cached module imports which isn't very meaningful
for subsequent loads. This patch updates the benchmark to toggle
the detection based on the presence of type field in the package.json,
and generates fixtures to benchmark fresh module loads.

PR-URL: https://github.com/nodejs/node/pull/55238
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2024-10-09 14:16:01 +00:00
Aviv Keller
71785889c8
lib: prefer logical assignment
PR-URL: https://github.com/nodejs/node/pull/55044
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: LiviaMedeiros <livia@cirno.name>
2024-10-09 06:42:16 +00:00
Rafael Gonzaga
834316d541
benchmark: add no-warnings to process.has bench
PR-URL: https://github.com/nodejs/node/pull/55159
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-30 20:27:39 +00:00
Sonny
090add7864
fs: refactoring declaratively with Array.fromAsync
Refs: https://github.com/nodejs/node/pull/51912
PR-URL: https://github.com/nodejs/node/pull/54644
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
2024-09-27 11:59:09 +02:00
Marco Ippolito
00d4f8073c
benchmark: create benchmark for typescript
PR-URL: https://github.com/nodejs/node/pull/54904
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2024-09-25 17:25:18 +00:00
jakecastelli
96ec7eede9
benchmark: add webstorage benchmark
PR-URL: https://github.com/nodejs/node/pull/55040
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2024-09-23 13:46:14 +00:00
Rafael Gonzaga
29357cb0ef
benchmark: include ascii to fs/readfile
PR-URL: https://github.com/nodejs/node/pull/54988
Reviewed-By: Daniel Lemire <daniel@lemire.me>
Reviewed-By: Raz Luvaton <rluvaton@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-19 20:15:47 +00:00
Aviv Keller
53cba82e55
benchmark: add dotenv benchmark
PR-URL: https://github.com/nodejs/node/pull/54278
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
2024-09-18 00:30:39 +00:00
Rafael Gonzaga
e4692eee75
benchmark: --no-warnings to avoid DEP/ExpWarn log
PR-URL: https://github.com/nodejs/node/pull/54928
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
2024-09-15 16:57:10 +00:00
Chengzhong Wu
d64835f97e
node-api: add external buffer creation benchmark
Add a micro benchmark for external buffer creation.

PR-URL: https://github.com/nodejs/node/pull/54877
Refs: https://github.com/nodejs/node/issues/53804
Refs: https://github.com/nodejs/node/issues/44111
Reviewed-By: Gabriel Schulhof <gabrielschulhof@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
2024-09-14 00:29:22 +00:00
Yagiz Nizipli
1d2603b53f
os: improve tmpdir performance
PR-URL: https://github.com/nodejs/node/pull/54709
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2024-09-11 14:46:30 +00:00
RafaelGSS
2f8d81ece3 benchmark: add buffer.isAscii benchmark
PR-URL: https://github.com/nodejs/node/pull/54740
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2024-09-06 17:46:49 +00:00
RafaelGSS
00291ea5dc benchmark: add buffer.isUtf8 bench
PR-URL: https://github.com/nodejs/node/pull/54740
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2024-09-06 17:46:49 +00:00
Rafael Gonzaga
9441ce1c90
benchmark: add access async version to bench
PR-URL: https://github.com/nodejs/node/pull/54747
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2024-09-05 20:56:54 +00:00
Rafael Gonzaga
fff1549551
benchmark: enhance dc publish benchmark
PR-URL: https://github.com/nodejs/node/pull/54745
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
2024-09-05 20:21:24 +00:00
RafaelGSS
248d5e0dac benchmark: add match and doesNotMatch bench
PR-URL: https://github.com/nodejs/node/pull/54734
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-05 15:02:30 +00:00
RafaelGSS
b26238132b benchmark: add rejects and doesNotReject bench
PR-URL: https://github.com/nodejs/node/pull/54734
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-05 15:02:29 +00:00
RafaelGSS
0b283c2b97 benchmark: add throws and doesNotThrow bench
PR-URL: https://github.com/nodejs/node/pull/54734
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-05 15:02:29 +00:00
RafaelGSS
688c885326 benchmark: add strictEqual and notStrictEqual bench
PR-URL: https://github.com/nodejs/node/pull/54734
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
2024-09-05 15:02:28 +00:00
Rafael Gonzaga
80a989f931
lib: add util.getCallSite() API
PR-URL: https://github.com/nodejs/node/pull/54380
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Claudio Wunder <cwunder@gnome.org>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-09-04 19:47:25 +00:00
Rafael Gonzaga
a63882bece
benchmark,doc: add CPU scaling governor to perf
PR-URL: https://github.com/nodejs/node/pull/54723
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
2024-09-04 19:21:18 +00:00
Rafael Gonzaga
133d2d9fad
benchmark,doc: mention bar.R to the list of scripts
PR-URL: https://github.com/nodejs/node/pull/54722
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-09-04 18:53:02 +00:00
Giovanni Bucci
03fe00e3da
benchmark: adds groups to better separate benchmarks
Fixes: https://github.com/nodejs/node/issues/26425
Co-Authored-By: Yaman Kassir <mestery@protonmail.com>
PR-URL: https://github.com/nodejs/node/pull/54393
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
2024-09-04 03:26:53 +00:00
Joyee Cheung
3b0617dd19 vm: migrate ContextifyScript to cppgc
This patch migrates ContextifyScript to cppgc-based memory
management using CppgcMixin.

PR-URL: https://github.com/nodejs/node/pull/52295
Refs: https://github.com/nodejs/node/issues/40786
Refs: https://docs.google.com/document/d/1ny2Qz_EsUnXGKJRGxoA-FXIE2xpLgaMAN6jD7eAkqFQ/edit
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Stephen Belanger <admin@stephenbelanger.com>
2024-08-30 16:58:31 +00:00
Early Riser
43f699d4d2
benchmark: fix benchmark for file path and URL conversion
PR-URL: https://github.com/nodejs/node/pull/54190
Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2024-08-25 13:41:13 +00:00
Yagiz Nizipli
7c76fa0aee
src: improve buffer.transcode performance
PR-URL: https://github.com/nodejs/node/pull/54153
Reviewed-By: Daniel Lemire <daniel@lemire.me>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-08-20 13:04:30 +00:00
Robert Nagy
ccf05ef751
buffer: use fast API for writing one-byte strings
PR-URL: https://github.com/nodejs/node/pull/54310
PR-URL: https://github.com/nodejs/node/pull/54311
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2024-08-15 01:01:05 +00:00
Rafael Gonzaga
4e6befd60e
benchmark: use assert.ok searchparams
PR-URL: https://github.com/nodejs/node/pull/54334
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matthew Aitken <maitken033380023@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com>
2024-08-14 18:43:01 +00:00
jakecastelli
87ee722873
benchmark: add stream.compose benchmark
PR-URL: https://github.com/nodejs/node/pull/54308
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-08-12 12:40:04 +00:00
Rafael Gonzaga
9b3d22dcf6
benchmark: rename count to n
It's a common approach to use n as number of iterations over the
benchmark. Changing it from count to n will also make
./node benchmark/run.js --set n=X more meaningful among other
benchmarks

PR-URL: https://github.com/nodejs/node/pull/54271
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2024-08-10 20:07:54 +00:00
Rafael Gonzaga
fde30a15e6
benchmark: change assert() to assert.ok()
PR-URL: https://github.com/nodejs/node/pull/54254
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-08-10 20:06:18 +00:00
Aviv Keller
0260bbeefa
benchmark: support --help in CLI
PR-URL: https://github.com/nodejs/node/pull/53358
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-08-06 18:21:27 +00:00
Yelim Koo
e1e7a417da
benchmark: remove force option as force defaults to true
PR-URL: https://github.com/nodejs/node/pull/54203
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2024-08-06 15:20:45 +00:00
Hüseyin Açacak
c852e222cb
path: fix relative on Windows
PR-URL: https://github.com/nodejs/node/pull/53991
Fixes: https://github.com/nodejs/node/issues/27534
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-08-06 09:40:23 +00:00
Rafael Gonzaga
ea5e77b1a5
benchmark: use assert.ok instead of assert
PR-URL: https://github.com/nodejs/node/pull/54176
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2024-08-04 13:29:34 +00:00
Stephen Belanger
d1229eeca4
lib: rewrite AsyncLocalStorage without async_hooks
PR-URL: https://github.com/nodejs/node/pull/48528
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Reviewed-By: Gerhard Stöbich <deb2001-github@yahoo.de>
2024-08-02 19:44:20 +00:00
Robert Nagy
76c8ba9d9b
buffer: use native copy impl
PR-URL: https://github.com/nodejs/node/pull/54087
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Daniel Lemire <daniel@lemire.me>
2024-08-02 09:19:41 +00:00
Chengzhong Wu
05a9413527
node-api: add property keys benchmark
PR-URL: https://github.com/nodejs/node/pull/54012
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
2024-07-29 11:19:52 +00:00
Gabriel Schulhof
2d1b4a8cf7 node-api: rename nogc to basic
Signed-off-by: Gabriel Schulhof <gabrielschulhof@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/53830
Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Michael Dawson <midawson@redhat.com>
2024-07-26 09:25:02 -07:00
Joyee Cheung
9f6dbfedd1 benchmark: add require-esm benchmark
PR-URL: https://github.com/nodejs/node/pull/52166
Refs: https://github.com/nodejs/node/issues/52134
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
2024-07-11 18:59:30 +00:00
Yagiz Nizipli
895fcb0546
benchmark: add cpSync benchmark
PR-URL: https://github.com/nodejs/node/pull/53612
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: LiviaMedeiros <livia@cirno.name>
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
2024-06-27 21:13:21 +00:00
Michaël Zasso
2eff28fb7a
tools: move ESLint to tools/eslint
Greatly simplify how ESLint and its plugins are installed.

PR-URL: https://github.com/nodejs/node/pull/53413
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2024-06-19 19:54:08 +00:00
Marco Ippolito
b5aae52c71
Revert "util: move util._extend to eol"
This reverts commit ac97a532f5.

PR-URL: https://github.com/nodejs/node/pull/53429
Refs: https://github.com/tape-testing/tape/issues/607
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-06-14 13:07:58 +00:00
Michaël Zasso
94c8178442
tools: move ESLint tools to tools/eslint
With ESLint flat config, we don't need a hack with `node_modules`
anymore to load ESLint plugins.
This commit moves the node-core plugin out of `tools/node_modules` and
creates a new `tools/eslint` directory to store ESLint tools.

PR-URL: https://github.com/nodejs/node/pull/53393
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Chemi Atlow <chemi@atlow.co.il>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
2024-06-11 06:58:51 +00:00
Michaël Zasso
881e196b19
benchmark: fix napi/ref addon
Refs: https://github.com/nodejs/node/pull/53212#issuecomment-2142566866
PR-URL: https://github.com/nodejs/node/pull/53233
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
2024-06-02 18:26:23 +00:00
Michaël Zasso
7e6d92c485
tools: update ESLint to v9 and use flat config
Closes: https://github.com/nodejs/node/issues/52567
PR-URL: https://github.com/nodejs/node/pull/52780
Fixes: https://github.com/nodejs/node/issues/52567
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
2024-05-23 19:45:18 +00:00