Sodium

Sodium

61M Downloads

Entity rendering performance significantly worse than vanilla on 1.21.5

Closed this issue · 5 comments

commented

Bug Description

A high entity count is handled very poorly by Sodium on 1.21.5. I first noticed this on servers that use a lot of display entities in their world.
In a world with ~1000 Zombies, vanilla performance is about double than what i get with Sodium:

Sodium

Image

Vanilla

Image

Tested with sodium-fabric-0.6.13+mc1.21.5 and fabric-api-0.123.0+1.21.5.

Reproduction Steps

Install latest sodium on 1.21.5 and summon a few hundred Zombies.
Compare with vanilla.

Log File

latest.log

Crash Report

crash-2025-05-08_03.37.12-client.txt

commented

This behavior can also be observed with Minecraft 1.21.5 and no other mods. The newer versions of the game are just slower for many players.

commented

This behavior can also be observed with Minecraft 1.21.5 and no other mods. The newer versions of the game are just slower for many players.

I am not comparing between versions. I am comparing between vanilla 1.21.5 and Sodium 1.21.5.
Are you saying sodium making my game run worse than vanilla is intended behavior?

commented

Are you saying sodium making my game run worse than vanilla is intended behavior?

Well, that's not a fair comparison. There are some rare cases, where vanilla performs better than Sodium on some PCs. For example, when I set 2 chunks render distance, vanilla gives me a bit more FPS; the issue here is scalability. You can destroy performance in a lot of ways, and rendering 1000 entities is one of them. And I wouldn't say this is a common scenario.

commented

Well, that's not a fair comparison.

Why exactly is that not fair? It's vanilla vs sodium without any other mods on the exact same world at the exact same position.
Yes, 1000 zombies is exaggerated, but it was just to demonstrate my point. The issue persists with less entities as well.

There are some rare cases, where vanilla performs better than Sodium on some PCs. For example, when I set 2 chunks render distance, vanilla gives me a bit more FPS;

I've set very reasonable settings, 12 chunks render distance, fancy graphics, 100% entity distance. i have a decently common PC setup (intel + 50s gen nvidia gpu). A few hundred entities is a very common scenario, especially on multiplayer servers.
Take for e.g. Wynncraft. The biggest MMORPG server. At the exact same position in Detlas on the exact same server, Sodium also performs slightly worse than vanilla.

Without Sodium:

Image

With Sodium:

Image

Sure, the difference is by no means as big, but it's still there which seems odd to me...
Using Sodium feels counterproductive. I don’t care about getting more FPS in situations where I already have 100+ fps anyways, if it ends up making the performance worse in the scenarios where I actually want those extra frames.

Look, I don't want to make Sodium look bad by cherry-picking situations where it performs worse than vanilla.
But in this case, I think it's kind of justified because it's precisely in low-FPS situations where this really matters. And it's not a very uncommon scenario either. I hope you understand my point.

commented

Your test of entity rendering performance is invalid because you're rendering 24% more chunks in the sodium case. Please come to our discord server for help on how to properly benchmark.