Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sodium causing clientside chunks leak #2586

Open
frosthuuuund opened this issue Jul 5, 2024 · 2 comments
Open

Sodium causing clientside chunks leak #2586

frosthuuuund opened this issue Jul 5, 2024 · 2 comments
Labels
P-high Priority: High S-needs-bisect Status: Needs a bisect T-bug Type: Bug
Milestone

Comments

@frosthuuuund
Copy link

frosthuuuund commented Jul 5, 2024

Bug Description

The Sodium installed causing clientsided chunks leak either by itself or makes it much noticeable.
Below i attached screenshot which illustrates the problem.
image

The amount of chunks on vanilla is a bit above from the starting point, but fairly enough to not set off the alarm.
image

Reproduction Steps

Install 1.21 with Fabric Mod Loader.
Use jdk-21.0.3.9-hotspot as your runtime.
Install Sodium 0.5.11.
Launch the game and create the new world with Creative mode.
Set the game rule keepInventory to true.
Equip elytra and firework.
Set a spawnpoint on 0 320 0.
Open F3 menu and follow one axis both in positive and negative direction on Gizmo debug crosshair.
Fly around 1000 blocks and kill yourself with the console command.
Do the same for the all axes.
Keep an eye on amount of geometry pool

Log File

https://paste.nolog.cz/?9a65e0dee4dddbf2#FdqxtsRo6zU2XyumZ9ZdM1jHRjVyBWyLbduZezS9er4x

Crash Report

https://paste.nolog.cz/?4daec5abb631e610#CbPBK2LbpBALLJ2WyPgmrXYqtFm7VHuTSM7DFgLrkPnr

@frosthuuuund frosthuuuund added the S-needs-triage Status: Needs triage label Jul 5, 2024
@jellysquid3 jellysquid3 added P-high Priority: High S-needs-bisect Status: Needs a bisect T-bug Type: Bug and removed S-needs-triage Status: Needs triage labels Jul 7, 2024
@jellysquid3
Copy link
Member

jellysquid3 commented Jul 8, 2024

I think this problem is related to a regression in Minecraft 1.21 itself, as the chunks don't seem to get unloaded there either. Unfortunately, it would seem Sodium exacerbates the issue, because it will only unload geometry when the chunks themselves are unloaded, and not when they fall out of the render distance.

We might need to rework things to address this.

@frosthuuuund
Copy link
Author

frosthuuuund commented Jul 8, 2024

Alright after the additional testing i got next information:

  1. This definitely happens on vanilla. If you teleports and kills yourself enough, you'll get OOM error, with 4GB allocated, you will run out of memory pretty fast.
  2. The dev snapshot showing fair amount of clientsided chunks, but still showing leaks in the geometry pool.
  3. This happens on 1.20.1 with Sodium 0.5.11 (Java 17) and also 1.20.4 (but Java 21, probably won't make a difference).

MCRcortex pushed a commit to MCRcortex/sodium-fabric that referenced this issue Jul 24, 2024
IMS212 pushed a commit that referenced this issue Aug 1, 2024
Co-authored-by: mcrcortex <{ID}+{username}@users.noreply.github.com>
IMS212 pushed a commit that referenced this issue Aug 1, 2024
Co-authored-by: mcrcortex <{ID}+{username}@users.noreply.github.com>
IMS212 pushed a commit that referenced this issue Aug 1, 2024
Co-authored-by: mcrcortex <{ID}+{username}@users.noreply.github.com>
IMS212 pushed a commit to IMS212/sodium-fabric that referenced this issue Aug 6, 2024
Co-authored-by: mcrcortex <{ID}+{username}@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P-high Priority: High S-needs-bisect Status: Needs a bisect T-bug Type: Bug
Projects
None yet
Development

No branches or pull requests

2 participants