Distant horizons filling up Memory too quickly which makes it unable to purge it.

Ok so i am making a modpack with a lot of different mods, but distant horizons by itself is having an insane effect on performance. Every couple of seconds, the game just freezes for half a second. I have narrowed down the problem to RAM. When opening the modpack without distant horizons, i get stable 60 fps, with shaders and 32 render distance. when opening f3 it shows the memory usage ticking up, reaching 90%, and then quickly jumping back down to 65% or so. as far as i know that is the intended behaviour for minecraft. As soon as i open the modpack with distant horizons, no other mods or settings changed, the normal frame rate drops a slight bit, to 55 fps, which is completely understandable. but it also freezes every couple of seconds. What appears to happen, is that the memory is filling up so fast, that it reaches 100% before it has time to purge, which freezes the game. Im not an expert at how mods work in the code, but i have the logs here https://mclo.gs/qonrm2t I know that supplementaries is incompatible with distant horizons but the issue was here long before i added supplementaries to the pack.
mclo.gs
NeoForge 1.21.1 Client Log [#qonrm2t]
5624 lines | 388 errors
Solution:
What are your GC/JVM tuning flags? You can try one of these sets: https://discord.com/channels/881614130614767666/1304910897658986570/1305234534492803165...
Jump to solution
13 Replies
Puhpine
Puhpine5d ago
how much ram do you have allocated?
LeffeDown
LeffeDownOP5d ago
8 GB of ram, but i have tested up to 14 gb, and it doesnt seem to affect it much. It just slightly increases the time between freezes from 5 to 7 seconds or something
Puhpine
Puhpine5d ago
can you try with just DH and see if it still happens?
LeffeDown
LeffeDownOP5d ago
even with just distant horizons it happens, but a lot less often. it seems as though the clearing is able to bring the memory down like 20% more when its just distant horizons, but it still peaks at 100% pretty often
Puhpine
Puhpine5d ago
thats probably expected meaning some mod is causing high memory usage when paired with DH
LeffeDown
LeffeDownOP5d ago
yeah i was already planning on just disabling half the mods at a time to test where the problem is it might also work a little better when chunks are pregenerated and im planning to use the modpack on a server so ill have to see how that works out
Solution
Miki_P98
Miki_P985d ago
What are your GC/JVM tuning flags? You can try one of these sets: https://discord.com/channels/881614130614767666/1304910897658986570/1305234534492803165
Miki_P98
Miki_P985d ago
Try reducing the CPU load preset And increase the allocated RAM to something higher to 8 What is your total RAM though? If 16, don’t surpass allocating 12 GB I would set it to 10
LeffeDown
LeffeDownOP5d ago
i have tried this and it doesnt seem to do much, unless i set the chunk render distance to something like 32 ill try 10 GB where can you check/change that on modrinth
Miki_P98
Miki_P985d ago
Second field above the allocation slider IIrc I think it was named JAVA arguments
LeffeDown
LeffeDownOP5d ago
i found it
Miki_P98
Miki_P985d ago
The effect of this setting are delayed as the already created tasks are not removed It can take up to time out seconds, by default 60s; times queue length per thread
LeffeDown
LeffeDownOP5d ago
i used the top one of the arguments you provided, and it seems to have helped in a way. The stutters every few seconds are gone, but the standard performance has gone down a bit that is luckily a lot easier to fix by changing settings in other mods and getting some performance mods added it seems like memory usage is higher than before but it peaks less and cleans up more often once the world loads in a bit it also seems to go up in performance so i think it has been solved
Want results from more Discord servers?
Add your server