Page 1 of 1

Minecraft use more ram than assigned

Posted: 14 Sep 2022, 11:23
by Sansebar
Hey following problem...
Minecraft use max possible Ram doesn´t matter what i tell it to use yes i know how to change that tried it even with Xmx2G but it still use 13GB so my system say 31,6GB in use when i play with opti and x512 pureBD...

Re: Minecraft use more ram than assigned

Posted: 14 Sep 2022, 11:56
by HanFox
Xmx isn't the only factor when Java uses memory.

There are plenty of discussions as to the why, such as this comment over on a thread on the Minecraft forums:
https://www.minecraftforum.net/forums/s ... comment=14

512x will need to use more whilst loading too as Java builds the atlas in system RAM before moving it to graphics VRAM.

Re: Minecraft use more ram than assigned

Posted: 14 Sep 2022, 12:23
by Sansebar
so i need more than 32GB of RAM to play with 512x?

Re: Minecraft use more ram than assigned

Posted: 14 Sep 2022, 14:07 
by HanFox
Sansebar wrote:
14 Sep 2022, 12:23
so i need more than 32GB of RAM to play with 512x?
No... you shouldn't really need more than 5 or 6 GB.

If you keep assigning more to Minecraft it'll keep using more because Java has a lazy garbage collector by default. It lets the memory fill up and up, then it cleans it when it gets full.

As the thread I linked says you shouldn't assign more than you need.

If you can load the game with 6GB and use 512x then you don't need to assign more, but Java may use more than you have the Xmx set to, because Xmx isn't the only factor for memory usage in a Java application.

That thread also has a link to this Reddit post which has some other Java switches you might want to try to help keep the memory management under control:
https://www.reddit.com/r/feedthebeast/c ... ry_with_a/

Re: Minecraft use more ram than assigned

Posted: 26 Sep 2022, 14:29
by Sansebar
the problem is that it is very laggi with 512x doesn´t matter how much RAM i assign. So i thought it need more RAM for it but where could the problem then come from? i have like 6fps on a high and pc (RTX 3080ti, i9 11900k, 32gb 3600MHz CPU Watercooled) do i need to change any other settings exept of RAM?

Re: Minecraft use more ram than assigned

Posted: 26 Sep 2022, 15:32
by HanFox
Please see the "Low FPS / poor performance on good hardware" section of the Help thread:
help-centre-f4/java-installation-patchi ... t1093.html