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

net: improve performance by destructuring primordials #30447

Closed
wants to merge 4 commits into from

Conversation

@gclv
Copy link
Contributor

gclv commented Nov 12, 2019

Refs: #29766

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
@gclv

This comment has been minimized.

Copy link
Contributor Author

gclv commented Nov 12, 2019

I'm actually getting a linter error on a line I didn't change (L538):

defineProperty(Socket.prototype, 'bufferSize', {
  get: function() { // eslint-disable-line getter-return
    if (this._handle) {
      return this[kLastWriteQueueSize] + this.writableLength;
    }
  }
});

Should I address that as part of this PR as well?

lib/net.js Outdated Show resolved Hide resolved
lib/net.js Show resolved Hide resolved
@lundibundi

This comment has been minimized.

Copy link
Member

lundibundi commented Nov 15, 2019

Also, it looks like we usually go with capitalized Object... in such cases, could you please replace them objectSetPrototypeOf -> ObjectSetPrototypeOf and such? Sorry for the typo in the first comment.

@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot

This comment has been minimized.

@gclv

This comment has been minimized.

Copy link
Contributor Author

gclv commented Nov 18, 2019

Also, it looks like we usually go with capitalized Object... in such cases, could you please replace them objectSetPrototypeOf -> ObjectSetPrototypeOf and such?

Ooops, renamed. Thanks for bearing with me!

@nodejs-github-bot

This comment has been minimized.

@nodejs-github-bot

This comment has been minimized.

gireeshpunathil added a commit that referenced this pull request Nov 19, 2019
Refs: #29766
PR-URL: #30447
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@gireeshpunathil

This comment has been minimized.

Copy link
Member

gireeshpunathil commented Nov 19, 2019

landed in 5e4d99a, thanks for the contribution!

BridgeAR added a commit that referenced this pull request Nov 19, 2019
Refs: #29766
PR-URL: #30447
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@BridgeAR BridgeAR mentioned this pull request Nov 19, 2019
targos added a commit that referenced this pull request Dec 1, 2019
Refs: #29766
PR-URL: #30447
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@BethGriggs BethGriggs mentioned this pull request Dec 9, 2019
MylesBorins added a commit that referenced this pull request Dec 17, 2019
Refs: #29766
PR-URL: #30447
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
@BethGriggs BethGriggs mentioned this pull request Dec 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
7 participants
You can’t perform that action at this time.