Skip to content

Commit

Permalink
test: remove test-diagnostics-channel-memory-leak.js
Browse files Browse the repository at this point in the history
There is no reliable way to detect this leak because:

1. We cannot reliably get a reference to the channel from the
  API to detect finalization without creating another strong reference.
2. This test does gc() and then checks memory usage - however the
  use of gc() disables code aging which can actually lead to increased
  memory usage overall, as it is not intended to be used to lower
  memory usage in the first place.
3. The implementation of diagnostics channels relies on ephemeron gc
  which is inefficient, it's not reliable to use the typical "create
  a lot of objects and see if it crashes" trick to check leaks.

To avoid flakiness in the CI, it's better to remove an unreliable
test altogether.
  • Loading branch information
joyeecheung committed Oct 28, 2023
1 parent 9c714d8 commit 72424dd
Showing 1 changed file with 0 additions and 24 deletions.
24 changes: 0 additions & 24 deletions test/parallel/test-diagnostics-channel-memory-leak.js

This file was deleted.

0 comments on commit 72424dd

Please sign in to comment.