-
Notifications
You must be signed in to change notification settings - Fork 88
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
Memory leak? #36
Comments
@waj can you provide the version of Erlang/OTP you are using? |
I'm experiencing the same behavior on my end (R16B01 and R15B03, OS X and Linux respectively).
Running |
Any solution available? |
I tried this in Erlang R16B02 on OS X and was not able to reproduce. So I just went all in with this function. run(N) ->
case N rem 10000 of
0 -> io:format("~p vms~n", [N]);
_ -> ok
end,
{ok, Ctx} = js_driver:new(),
true = js_driver:destroy(Ctx),
run(N + 1). which I figured was sure to expose the issue; however, it was only able to use at most 1GB of memory, and it reclaimed memory, just not as quickly as I'd have expected it to. Even still, this is a contrived example that really isn't a good use case. Is there some example of an application that this is causing a problem for? If there's no further activity on this issue, we'll consider a fix not necessary. |
I did some tests on various platforms (Centos, OSX) and Erlang releases - same effect = memory leaks. Please try to make simple test on the OS X:
You should see memory leaks with call stack like this:
I have a suspicion that the I have upgraded the spidermonkey to 1.8.5 and it seems to work properly now. |
I'm having the same issue:
I've attached the memory graph seen by Munin. |
Maybe I'm doing something wrong, but if I continuously create and destroy JavaScript VM instances the process memory increases all the time:
Any thoughts? Should I do this in some other way?
The text was updated successfully, but these errors were encountered: