embeddedt / embeddium

An open-source client performance mod for Minecraft (based on Sodium 0.5.8) prioritizing reliability & mod compatibility
https://legacy.curseforge.com/minecraft/mc-mods/embeddium
GNU Lesser General Public License v3.0
193 stars 74 forks source link

Updated Embeddium version with loading specific biomes will become laggy #294

Closed FlappiBakuse closed 4 months ago

FlappiBakuse commented 4 months ago

Bug Description

I'm using an Intel Arc A770 graphics card with the latest graphics drivers, when I start the game with the latest Embeddium version and create worlds to load specific biomes (eg. jungle, mangrove swamp) the game will become extremely laggy (other biomes will not have this problem), this problem disappeared when I downgraded Embeddium to version 0.3.12.

The following two images will show the difference in performance between different Embeddium versions. (render distance are all set to 32)

2024-05-14_15 47 02

2024-05-14_16 05 43

Reproduction Steps

  1. Install only Embeddium and the latest Forge loader and start the game.
  2. Create single biome world with jungle or mangrove swamp biomes.
  3. Walk around randomly and the game starts to lag.

Log File

debug.log latest.log

embeddedt commented 4 months ago

Hi, thanks for opening an issue. Is performance with this test build similar to 0.3.12? test_build.zip

FlappiBakuse commented 4 months ago

Yes, it looks much better now. Thanks for the work!

2024-05-14_22 37 58

embeddedt commented 4 months ago

That isn't a fix, it was just me verifying which change caused the problem. :laughing: I'm working on a proper fix now.

embeddedt commented 4 months ago

Okay, does this also fix the issue?

fix.zip

FlappiBakuse commented 4 months ago

It looks like this version is more unstable compared to the last test version of frametime.

2024-05-14_23 04 01

embeddedt commented 4 months ago

How about this? fix2.zip

FlappiBakuse commented 4 months ago

It's pretty close to the first test version, but still feels like it has some minor lag.

2024-05-14_23 20 44

embeddedt commented 4 months ago

I think it will be close enough. The original test version isn't suitable because it reverts a fix for a crash. The new code strikes a balance between attempting to emulate the old behavior enough to not cause significant lag, while also preventing the excessive memory usage that caused the crash in the first place.

FlappiBakuse commented 4 months ago

I think there's not a problem, at least it's already in a fully playable state, thanks again for your work.

embeddedt commented 4 months ago

The fix has been released in 0.3.19.