r/ProgrammerHumor • • Oct 07 '26

Meme minecraftException

Post image
9.3k Upvotes

830 comments sorted by

View all comments

Show parent comment

14

u/Jim_skywalker Oct 07 '26

So that’s why modded Minecraft can have reoccurring lag spikes.

11

u/trash-_-boat Oct 07 '26

It's also why you don't want to give Minecraft TOO much RAM. Because then it will do the GC in bigger chunks, which will cause an even longer pause.

4

u/FabioTheFox Oct 07 '26

I feel like this is more of a Java specific quirk, I've not seen this with other languages

3

u/fearless-fossa Oct 07 '26

Not a Java programmer, but as someone who hosts a lot of enterprise Java applications I feel like this is mostly gone. A few legacy things still running Java 8 actually perform better with the JVM set to 4 GB instead of something like 16, but stuff with Java 21 will see no practical performance difference, at least not in out apps.

1

u/awesome-alpaca-ace Oct 09 '26

What about Java 27 javac with Java 8 output?

1

u/Ok-Scheme-913 Oct 09 '26

The object model will still be 27's, not 8s, so you still get almost all the improvements that went into the jvm

2

u/Ok-Scheme-913 Oct 09 '26

Meh, I don't think it's true. Also, you are better off setting the ratio of what percent of the bigger ram you want free at all times.

The GC is pretty good at figuring out the rest.

-4

u/sambeau Oct 08 '26

Modern Minecraft is written in C++. At least the versions on anything that isn’t a plain old PC.

3

u/Jim_skywalker Oct 08 '26

I mean java edition is still in Java right?

3

u/Nidrax1309 Oct 08 '26

You mean the ballsucking Bedrock / Windows Store Edition? No, that's not real Minecraft. Real Minecraft still runs on Java.