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

fix: CtQueryImpl handling of preallocated exceptions #1759

Merged
merged 1 commit into from
Nov 29, 2017

Conversation

pvojtechovsky
Copy link
Collaborator

The new Templating engine (#1686) uses CtQuery a lot and Java runtime decided to optimize exception handling in runtime. It was the reason why many tests started to fail with strange exception without the stacktrace.

This PR handles such "preallocated exceptions" well.

See java release notes for details:

The compiler in the server VM now provides correct stack backtraces for all "cold" built-in exceptions.
For performance purposes, when such an exception is thrown a few times, the method may be recompiled. After recompilation, the compiler may choose a faster tactic using preallocated exceptions that do not provide a stack trace. To disable completely the use of preallocated exceptions, use this new flag: -XX:-OmitStackTraceInFastThrow.

@monperrus
Copy link
Collaborator

super interesting!

@pvojtechovsky pvojtechovsky deleted the fixQueryPrealocatedExceptions branch September 1, 2018 07:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants