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

OutOfMemoryError in 9k on code with very large methods #3016

Closed
bbrowning opened this issue Jun 3, 2015 · 2 comments
Closed

OutOfMemoryError in 9k on code with very large methods #3016

bbrowning opened this issue Jun 3, 2015 · 2 comments

Comments

@bbrowning
Copy link
Contributor

@bbrowning bbrowning commented Jun 3, 2015

When running TorqueBox 4's rubocop task under JRuby 9k, we sometimes get an OutOfMemoryError. After some debugging on IRC, it looks like the very large advance method in the parser gems' lib/parser/lexer.rb is causing a non-fatal OOM in the JIT compiler which ends up backing up the JIT queue and eventually OOMing the entire application in a fatal way.

Here's a gist of the OOMs with jit logging enabled - https://gist.github.com/bbrowning/a3d4e9d9fe871b36b0e7

@bbrowning
Copy link
Contributor Author

@bbrowning bbrowning commented Jun 4, 2015

I mentioned this on IRC, but to make sure you see it this commit forgot to adjust Constants.JIT_MAX_SIZE_LIMIT from 30,000 down to a value of 2,000. Thus, unless I run with -Xjit.maxsize=2000, I still see the OOMs happening.

@enebo
Copy link
Member

@enebo enebo commented Jun 5, 2015

I adjusted this yesterday (note for posterity).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants