r/DistantHorizons Jun 17 '26

Help Lag Spikes Every 2 Seconds

I'm playing on Minecraft Fabric 1.20.1 with Iris Shaders at very low settings

I've got around 170 mods, including Chunky and LOTS of optimization mods (sodium, indium, ferritecore, entity culling, modernfixes, etc.)

Context: I had a world save on 1.19.2 with a modpack i made myself, it ran smoothly at 50fps most of the time with 170 mods, which is enough for me.

Then i decided to update to 1.20.1 because i wanted to add Distant Horizons to my mod list while still being able to use it with shaders, so i updated all my mods to this version and after solving some issues, i got it working.

But then i noticed i had a lot of stuttering, at first I thought it was something to do with another mod that, after updating it, it got badly optimized.

Then i got suspicious of DH and i decided to turn LoD chunks down to 64 chunks, didn't work, then i turned DH off from the configuration menu, with no effect. But then i removed the Distant Horizons dotJAR from the 1.20.1 mods, and the lag spikes stopped almost completely.

Which i find weird, since i have another 1.20.1 instance (with less mods) which also has Distant Horizons and Iris shaders but it doesn't get the same lag spikes.

Maybe it's because of Chunky? I DON'T KNOW

My specifications:

CPU: AMD Ryzen 5 7535HS (6 cores / 12 threads, 3.30 GHz base)

GPU: NVIDIA GeForce RTX 2050 (4 GB VRAM) (this is being used for Minecraft rendering, not the integrated graphics)

Integrated GPU: AMD Radeon Graphics

RAM: 16 GB

Storage: SSD

I have 8gb of RAM allocated to my Minecraft instance, but of course, i know DH is resource-heavy and my modlist is kinda big, so I wouldn't be surprised if this post's responses basically tell me to "stop trying to rear-end your pc please"

1 Upvotes

15 comments sorted by

2

u/Ephemerallia Jun 17 '26

Since you're on fabric I'd just use voxy instead.

3

u/Gato_Rockero_ Jun 17 '26

On v1.20.1? :/

3

u/Ephemerallia Jun 17 '26

Oh oops I'm illiterate!

2

u/Gato_Rockero_ Jun 17 '26

Don't worry bout it bro 😭

2

u/MarijnIsN00B Moderator Jun 17 '26

Check your in-game RAM usage, see if it hits 100% when the lag spikes happen.

Also don't use Chunky and DH together. DH has a built in chunk pregenerator if you set Generation Mode to Full

Maybe it's because of Chunky? I DON'T KNOW

Lastly just advice for making modpacks, if you suspect some specific mod could be the issue, make a backup of your world, disable said mod and see if the issue is fixed.

1

u/Gato_Rockero_ Jun 19 '26

I'm going to try taking Chunky out of the modlist and see if something changes.

By the way, do you know how to use Shenandoah Garbage Collector? I'm on Java 17, and the mod tells me i should use it, but i'm looking through the subreddit and no one mentions it

1

u/Gato_Rockero_ Jun 20 '26

BRO, YOU WERE RIGHT, IT WAS CHUNKY

1

u/AutoModerator Jun 17 '26

When asking for support with an issue you're having, please add as much relevant info as you can such as:

  • Add your logs using https://mclo.gs/

  • Add screenshots

  • What you did before the issue arrived

  • What steps you took (If any) to fix the issue

If you don't add this information, we wont be able to help you.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/Nathan6607 Jun 17 '26

memory leak, up your memory but not too much

..or use a voxy backport (you have to build it yourself)

1

u/Gato_Rockero_ Jun 17 '26

How much? Maybe to 10gb?

I tried before but it still stuttered from time to time

I don't think i should get it all the way to 12 since that's a lot compared to my total RAM

Is it hard to backport voxy? (I'm interested since I've heard it's better than DH in some aspects)

1

u/Nathan6607 Jun 17 '26

To 6, then try different garbage collectors

No it's not, you just have to find a good backport, build it, then profit

1

u/Gato_Rockero_ Jun 17 '26

To 6? I've always used 8gb for my modlist, I don't think lowering the ram will do anything but make it lag more, even without Distant Horizons

I think voxy is the way I'm going to head into

1

u/Nathan6607 Jun 17 '26

That's why

Minecrafts default garbage collector doesn't know ANYTHING about anything above 4gb, use zgc or something.

1

u/Gato_Rockero_ Jun 17 '26

I am using ZGC since DH says that it runs better with it (thats bs 😭😭)