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

No need to use locks for reflection stuff. Use single-racy reads instead. #163

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

turbanoff
Copy link
Contributor

Classes sun.misc.Unsafe and java.lang.reflect.Method are effectively immutable. It means we don't need to lock on their initialization. Single racy-read is enough.

@turbanoff turbanoff force-pushed the avoid_lock_in_ClassLoaderWeavingAdaptor branch from 014ad9d to d3ae76b Compare April 20, 2022 19:55
@kriegaex kriegaex requested a review from aclement April 21, 2022 03:03
@kriegaex kriegaex added the enhancement New feature or request label Apr 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants