Skip to content

Conversation

ofrobots
Copy link
Contributor

@ofrobots ofrobots commented Nov 9, 2017

Depending on the allocator, existing code leaks memory.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

src: perf_hooks

CI: https://ci.nodejs.org/job/node-test-pull-request/11318/

@nodejs-github-bot nodejs-github-bot added the c++ Issues and PRs that require attention from people who are familiar with C++. label Nov 9, 2017
@ofrobots ofrobots requested a review from jasnell November 9, 2017 06:15
@mscdex mscdex removed the v9.x label Nov 9, 2017
@addaleax
Copy link
Member

addaleax commented Nov 9, 2017

I have no idea how Coverity tracks these things but is this maybe the reason for https://github.com/ofrobots/node/blob/59a012aeb976347d6975c82fb376b5db41da146c/src/node_perf.cc#L217 ?

Also, out of curiousity, on which systems was this noticeable?

@ofrobots
Copy link
Contributor Author

@addaleax At Google we use sized deletes, which caught this once we upgraded to 8 LTS.

The coverity comment you point you to is possibly related to this, but /cc @bnoordhuis in case there was another reason to add it.

@bnoordhuis
Copy link
Member

Not the same thing. leaked_storage is for when Coverity can't track where a heap allocation is freed.

Depending on the allocator, existing code leaks memory.

PR-URL: nodejs#16898
Reviewed-By: Franziska Hinkelmann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Khaidi Chu <[email protected]>
@ofrobots ofrobots merged commit d37789d into nodejs:master Nov 17, 2017
@ofrobots ofrobots deleted the perf-sized-delete branch November 17, 2017 01:22
@ofrobots
Copy link
Contributor Author

Landed as d37789d.

MylesBorins pushed a commit that referenced this pull request Dec 12, 2017
Depending on the allocator, existing code leaks memory.

PR-URL: #16898
Reviewed-By: Franziska Hinkelmann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Khaidi Chu <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Dec 12, 2017
gibfahn pushed a commit that referenced this pull request Dec 19, 2017
Depending on the allocator, existing code leaks memory.

PR-URL: #16898
Reviewed-By: Franziska Hinkelmann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Khaidi Chu <[email protected]>
@gibfahn gibfahn mentioned this pull request Dec 20, 2017
gibfahn pushed a commit that referenced this pull request Dec 20, 2017
Depending on the allocator, existing code leaks memory.

PR-URL: #16898
Reviewed-By: Franziska Hinkelmann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Khaidi Chu <[email protected]>
@gibfahn gibfahn mentioned this pull request Dec 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c++ Issues and PRs that require attention from people who are familiar with C++.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants