Skip to content
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 and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v8.x backport] lib: faster type checks for some types #16073

Closed
wants to merge 2 commits into from

Conversation

TimothyGu
Copy link
Member

Backport #15663.

Benchmark:

util/type-check.js millions="5" argument="true" version="native" type="TypedArray": 63,811,486.37128951
util/type-check.js millions="5" argument="false-primitive" version="native" type="TypedArray": 71,146,804.67249525
util/type-check.js millions="5" argument="false-object" version="native" type="TypedArray": 71,416,827.44141889
util/type-check.js millions="5" argument="true" version="js" type="TypedArray": 68,488,900.62027659
util/type-check.js millions="5" argument="false-primitive" version="js" type="TypedArray": 89,352,270.55824636
util/type-check.js millions="5" argument="false-object" version="js" type="TypedArray": 89,348,717.89593348
util/type-check.js millions="5" argument="true" version="native" type="Uint8Array": 62,412,541.30586808
util/type-check.js millions="5" argument="false-primitive" version="native" type="Uint8Array": 78,526,852.57919955
util/type-check.js millions="5" argument="false-object" version="native" type="Uint8Array": 61,323,832.65270625
util/type-check.js millions="5" argument="true" version="js" type="Uint8Array": 75,241,599.64784524
util/type-check.js millions="5" argument="false-primitive" version="js" type="Uint8Array": 82,195,138.88742764
util/type-check.js millions="5" argument="false-object" version="js" type="Uint8Array": 74,586,310.7567035
Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

lib

@nodejs-github-bot nodejs-github-bot added lib / src Issues and PRs related to general changes in the lib or src directory. v8.x labels Oct 7, 2017
@TimothyGu
Copy link
Member Author

Copy link
Member

@addaleax addaleax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM if CI is happy

@TimothyGu
Copy link
Member Author

Backport-PR-URL: nodejs#16073
PR-URL: nodejs#15663
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Backport-PR-URL: nodejs#16073
PR-URL: nodejs#15663
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@evanlucas
Copy link
Contributor

Landed in 67aed79 and b1a68f5. Thanks!

@evanlucas evanlucas closed this Oct 23, 2017
evanlucas pushed a commit that referenced this pull request Oct 23, 2017
Backport-PR-URL: #16073
PR-URL: #15663
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
evanlucas pushed a commit that referenced this pull request Oct 23, 2017
Backport-PR-URL: #16073
PR-URL: #15663
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@TimothyGu TimothyGu deleted the v8.x-15663 branch March 26, 2018 02:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lib / src Issues and PRs related to general changes in the lib or src directory.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants