Tau-ri-Dev / Mod-JSG-1.12.2

Just Stargate Mod for Minecraft (1.12.2)
https://JustSGMod.eu
Other
33 stars 22 forks source link

Bug: JSG Exceeds Java Instance's Allocated Memory During Texture Loading and Breaks GC #334

Closed jhammerberg closed 4 months ago

jhammerberg commented 4 months ago

Describe the bug During initialization on Forge, JSG will exceed the allocated memory of Minecraft while loading the event horizon textures and from then on, garbage collection will be broken causing the instance to use 3 to 4 times the amount of memory it's been allocated, after initialization.

To Reproduce Steps to reproduce the behavior:

  1. Allocate a specific amount of memory to a forge instance, under 10GB will make it more noticeable
  2. Launch JSG Version 4.11.2.6-client
  3. During event horizon texture loading, monitor the amount of memory the Java instance uses with task manager or other external tools
  4. The amount will exceed the amount specified before launch, using the game further will increase this amount more suggesting the garbage collection system is not working correctly.

Expected behavior The amount of memory taken up by the Java instance should remain under the amount it's allocated.

Screenshots Memory Allocated Memory Used

Logs latest.log With texture logging turned on. The issues start to occur around line 660

Mod version jsg-1.12.2-4.11.2.6-client

Additional context The memory used by Forge will not show the increased amount, only task manager or other external tools to measure memory usage will.

My whole JSG config (as .zip) The default configuration, the only mod loaded.

jhammerberg commented 4 months ago

I'm dumb, this is normal behavior for Java, JSG just makes it really obvious https://knowledge.informatica.com/s/article/629910?language=en_US