querystring: simplify stringify method by ZYSzys · Pull Request #26591 · nodejs/node (original) (raw)
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation11 Commits1 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
Since there is no obvious improvement in stringify
method, try to simplify stringify
method without performance regression.
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes- tests and/or benchmarks are included
- commit message follows commit guidelines
CI: https://ci.nodejs.org/job/node-test-pull-request/21657/
Benchmark CI: https://ci.nodejs.org/view/Node.js%20benchmark/job/benchmark-node-micro-benchmarks/305/console
17:41:31 confidence improvement accuracy (*) (**) (***)
17:41:31 querystring/querystring-stringify.js n=10000000 type='array' 0.27 % ±0.97% ±1.30% ±1.69%
17:41:31 querystring/querystring-stringify.js n=10000000 type='array0' *** 2.52 % ±0.88% ±1.17% ±1.52%
17:41:31 querystring/querystring-stringify.js n=10000000 type='encodelast' -0.09 % ±1.05% ±1.40% ±1.82%
17:41:31 querystring/querystring-stringify.js n=10000000 type='encodemany' -0.77 % ±1.14% ±1.52% ±1.99%
17:41:31 querystring/querystring-stringify.js n=10000000 type='noencode' 1.01 % ±1.70% ±2.27% ±2.95%
So slightly the performance improved, but at least an improvement right ?
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code changes are LGTM. The case optimized is very rare, thus adding extra benchmark types does not seem right to me.
BridgeAR added the author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
label
ZYSzys changed the title
querystring: slightly improve stringify performance querystring: simplify stringify method
BridgeAR pushed a commit to BridgeAR/node that referenced this pull request
PR-URL: nodejs#26591 Reviewed-By: Ruben Bridgewater ruben@bridgewater.de
BethGriggs pushed a commit that referenced this pull request
PR-URL: #26591 Reviewed-By: Ruben Bridgewater ruben@bridgewater.de Signed-off-by: Beth Griggs Bethany.Griggs@uk.ibm.com
BethGriggs pushed a commit that referenced this pull request
PR-URL: #26591 Reviewed-By: Ruben Bridgewater ruben@bridgewater.de Signed-off-by: Beth Griggs Bethany.Griggs@uk.ibm.com
Labels
PRs that have at least one approval, no pending requests for changes, and a CI started.
Issues and PRs related to the built-in querystring module.