-
Notifications
You must be signed in to change notification settings - Fork 84
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 some weird memory leak from changing dimensions #581
Conversation
Warning: 2 uncommitted changes |
isn't the map supposed to remove the oldest entry since 20 elements? is that broken? |
probably, as you can see in the screenshot of memory dump |
what java version are you using? in gt5 dev env it definitely don't do it |
jdk-22 |
Won't this create a memory problem since this method is called every time you hover over an object in world? |
and this can't solve problem, only hide it |
#583 - this PR solved the problem better |
This map has some race condition problem. I bet this is just the fallout of that and neither PR would really work. I suggest to wrap it around synchronizedMap instead. GT5 dev env doesn't have this issue because there is simply no contention there. The top offender lives in GC where it's calling getFluid as part of its tooltip event handler. |
Changed to ItemStackMap

before: