Closed
Description
Steps to reproduce:
$ cat test.js
'use strict';
for (var i = 0;; ++i) {
if (i % 100 == 0) gc();
new class{};
}
$ node --expose-gc test.js & top -p $! && kill -9 $! # use q to quit
Observe reserved memory slowly grow. This will eventually cause out-of-memory.
This was first observed here. Note that this does not reproduce with d8 (V8's test shell), where the memory use stabilizes fairly quickly.