Skip to content

Conversation

@graalvmbot
Copy link
Collaborator

This optimizes Throwable#fillInStackTrace by storing raw instruction pointers (IPs) instead of eagerly populating the StackTraceElement array. The raw IP backtrace is later decoded in StackTraceElement#of(Object, int) (which is called from Throwable#getOurStackTrace). Since raw IPs are only stable for AOT compiled methods, the optimization is disabled if runtime compilation is enabled. Runtime compilation support is planed for follow-up work.

Throwable objects stored in the image heap are reset and do not hold stack trace information. In case the Throwable object is writable (see Throwable#Throwable(String, Throwable, boolean, boolean)), a new stack trace can be constructed by calling Throwable#fillInStackTrace manually.

zapster added 30 commits April 21, 2023 16:02
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label May 2, 2023
@graalvmbot graalvmbot merged commit 12022ff into master May 2, 2023
@graalvmbot graalvmbot deleted the je/svm-fill-in-stacktrace-GR-34212 branch May 2, 2023 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OCA Verified All contributors have signed the Oracle Contributor Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants