[1.16.5] Some deprecated calls and excessive memory consumption (Leak?)
FrannDzs opened this issue ยท 28 comments
Context
- Minecraft Version: 1.16.5
- MineColonies Version: 0.13.622
Logs
Steps to reproduce the issue / details
- Install Minecraft 1.16.5
- Install Forge 36.0.42
- Install MineColonies 0.13.622
Hello, I am seeing several warnings in the registry such as:
[17feb2021 13:25:59.180] [Worker-Main-3/WARN] [net.minecraft.client.renderer.model.ModelBakery/]: Unable to resolve texture reference: #missing in minecolonies:block/blockhutbeekeeper
[17feb2021 13:26:39.633] [Render thread/WARN] [net.minecraftforge.common.ForgeHooks/]: Called deprecated GlobalEntityTypeAttributes#put for minecolonies:citizen, use EntityAttributeCreationEvent instead.
and I have a memory leak apparently. In Structurize or Minecolonies but I can't figure it out.
Notes
In the last few days some of the MineColonies or Structurize updates broke something as my RAM is constantly filling up, pushing up to 98%, when before at 80% it would restart the garbage collection cycle, is there some major change that makes this consume more RAM? Maybe it's Structurize and not MineColonies but I don't know how to find out.
This worries me a lot.
Viewers
I can provide F3 screenshots if you wish to compare RAM usage between one version and another. Greetings!
Can you isolate this issue to structurize and minecolonies only?
Also, try without/with optifine
Can you isolate this issue to structurize and minecolonies only?
Also, try without/with optifine
it seems I was running minecolonies with an older version of structurize, don't ask me how it happened, I reinstalled the whole game and after updating structurize it was fixed :s
Before Minecolonies update its dependency was fine, but I'm sure there is a leak because just staying in the menu comes a time that the memory fills up more and more until it is completely occupied.
The new update did add a lot new blocks, buuut also a bunch of UI changes on the client side. Could be some openGL leak or so.
It is likely since Optifine has also released a preview version these days. I can't imagine playing without Optifine, that's why I don't test without it.
In the log I see Render errors and if I'm not mistaken they are related to Optifine, so it's very likely what you saying.
It's okay for Minecolonies to add blocks but I think it's overkill this time, I'll try to figure it out at this time to see where the leak is.
yea they do that a lot. however they're closed source so nothing we can do
i just sounded like ashers, didn't i?
Couldn't see any optifine related errors in this log. If you got another one with them, I'd accept it and forward it to the optifine dev.
Couldn't see any optifine related errors in this log. If you got another one with them, I'd accept it and forward it to the optifine dev.
Isn't this what is causing the leak?
Name: structurize:side_framed_warped_brick_timber_frame Expected: 2474 Got: 3348
[17feb.2021 17:16:47.401] [Render thread/WARN] [net.minecraftforge.registries.ForgeRegistry/REGISTRIES]: Registry Item: Object did not get ID it asked for. Name: structurize:side_framed_warped_stone_brick_timber_frame Expected: 2475 Got: 3349
[17feb.2021 17:16:47.401] [Render thread/WARN] [net.minecraftforge.registries.ForgeRegistry/REGISTRIES]: Registry Item: Object did not get ID it asked for. Name: structurize:side_framed_warped_cream_brick_timber_frame Expected: 2476 Got: 3350
No, shouldn't be.
I think that's it as previous versions did not throw this error, is it due to Forge then?
net.minecraftforge.registries.ForgeRegistry/REGISTRIES]
Okay, try this:
Rollback Minecolonies to the previous version and tell us how many blockstates there are.
Okay, try this:
Rollback Minecolonies to the previous version and tell us how many blockstates there are.
I had a problem and I am reinstalling Minecraft completely, it already happened to me 3 times today, I don't know what is happening but they are going to make me sick :p all carnival weekend reporting errors and working, God.
Where do I look at that?
Sorry, not how many blockstates. But load up minecolonies/structurize in the previous one and tell us the difference in memory.
A visualvm dump would also be appretiated.
I have more problems, what happens today?
Now when starting Forge without Optifine it throws this:
[17feb2021 22: 33: 03.369] [Thread-21 / INFO] [net.minecraft.client.renderer.GlDebugTextUtils /]: OpenGL debug message, id = 1281, source = API, type = ERROR, severity = HIGH, message = GL_INVALID_VALUE error generated. Size and / or offset out of range.
Something like this never happened to me and today I have been using this version of forge with optifine, what happens? :(
Let me see in VisualVM with more time, it is late and I got tired of all this. I will find out more and let you know
Sorry, not how many blockstates. But load up minecolonies/structurize in the previous one and tell us the difference in memory.
The game threw those errors and did not start completely
Can you isolate this issue to structurize and minecolonies only?
Also, try without/with optifine
Hello! I am reopening to confirm the memory leak. I have almost 70 mods installed of which at most they consume me 1500mb. When I install MineColonies together with Structurize it reaches the 2GB I have set as maximum, but it never picks up its garbage. If I start Minecraft and leave it in the menu without starting a world it also fills up the memory. I don't think Minecolonies occupies more than 600mb in ram memory, so I'm going to use JVisualVM to see if I can find where the problem is, I'm sure there is a memory leak, although I don't know how to use it and this is a bit of a choke point.
Can Optifine be the cause of a memory leak in Minecolonies/Structurize?
Structurize adds a very large amount of decorative blocks. 600mb seems like a lot, but minecraft is also not super efficient.
Ok, few things:
- optifine doesnt work well with java 9+
- You save broken mod download probably
[17feb.2021 17:17:41.049] [ForkJoinPool.commonPool-worker-3/ERROR] [net.minecraftforge.eventbus.EventSubclassTransformer/EVENTBUS]: An error occurred building event handler java.lang.ClassNotFoundException: icyllis.caffeine.cache.RemovalCause
- Either weak cpu or weak sound drivers
[17feb.2021 17:26:17.158] [SoundControl Sound Processor/WARN] [SoundControl/SoundFXProcessor]: SoundControl Sound Processor is lagging; behind 4745 msecs
- You have kinda old and weak gpu, also latest drivers for it are quite old, might be worth getting something newer, gtx600 series still has new drivers but getting gtx700 series shouldn't be expensive too nowadays
You can definitely try to fix 1 and 2, 4 would be definitely worth too but it shouldn't be a problem (as mojang supports old intel integrated graphics too)
Ok, few things:
- optifine doesnt work well with java 9+
- You save broken mod download probably
[17feb.2021 17:17:41.049] [ForkJoinPool.commonPool-worker-3/ERROR] [net.minecraftforge.eventbus.EventSubclassTransformer/EVENTBUS]: An error occurred building event handler java.lang.ClassNotFoundException: icyllis.caffeine.cache.RemovalCause
- Either weak cpu or weak sound drivers
[17feb.2021 17:26:17.158] [SoundControl Sound Processor/WARN] [SoundControl/SoundFXProcessor]: SoundControl Sound Processor is lagging; behind 4745 msecs
- You have kinda old and weak gpu, also latest drivers for it are quite old, might be worth getting something newer, gtx600 series still has new drivers but getting gtx700 series shouldn't be expensive too nowadays
You can definitely try to fix 1 and 2, 4 would be definitely worth too but it shouldn't be a problem (as mojang supports old intel integrated graphics too)
Hello, good morning, you are absolutely right, my pc is a toaster :p. But it is capable of running Minecraft with 70 mods at a stable 60FPS, that's why the massive memory consumption was inexplicable. It seems Optifine released 2 more versions since I posted this and the bug was fixed (happily).
For the bug you mention about the broken mod the creator said this:
"Just ignore it, it's because of clearing cached nodes for text rendering. When you change GUI scale, font engine will be reloaded and the cache will be cleared".
Also my graphics card is very old, you are right, but it is enough to allow me to play League of Legends at maximum quality without problems, and I don't use the 391.35 version provided by Nvidia, I found a more recent version modified by the Xtreme-G Drivers team:
I recommend these drivers over Nvidia, supposedly they have better performance than the original ones.
Thank you all for your attention, really, have a nice weekend!