sp614x / optifine

1.81k stars 417 forks source link

[1.12.2] Memory leak on Alt-Tab with fullscreen and certain shaders packs #2019

Closed Cyphall closed 4 years ago

Cyphall commented 5 years ago

I'm experiencing some huge memory leaks while alt tabing using OptiFine 1.12.2 HD U E2 with some shaders packs enabled (does not happens with all packs).

It happens only in fullscreen, with SEUS Renewed 1.0.0 (biggest memory leak, up to 500 MB/s increase) and Sildur's Vibrant Shaders 1.18 High-Motionblur (smaller memory leak but still present) but not with KUDA Shaders 6.1.

For some reasons, there is no memory leak if I set my max FPS to 135 or bellow but it starts happening at 140, and the higher the FPS limit is, the faster the RAM increases, with around 5 MB/s at 140 FPS and 500+ MB/s at Unlimited FPS for SEUS Renewed.

I've tried to make a new .minecraft install and leaving as much options as I could to default (basically just installing optifine and selecting the shaders pack in-game) and it is still happening. So far, I don't have this issue in 1.13.

sp614x commented 5 years ago

Does it happen in all worlds? When the memory allocation increases, do you get the GC lag spikes (orange in the lagometer) much more often?

Cyphall commented 5 years ago

So far it happens both on normal worlds and superflat.

I think I wasn't very clear sorry. The leak starts when I alt-tab from the game (with fullscreen enabled only) and the memory increases while the game is unfocused. When I go back to the game, it freezes for some seconds, depending of the amount of leaked memory (freeze for ~3sec with a 1GB leak and ~15sec with a 4.5 GB leak). Also, it doesn't happens in menus, only when a world is loaded.

Cyphall commented 5 years ago

Here are my specs: Intel Core i5-7600K @4.6GHz Nvidia GTX 1070 16GB Corsair Vengeance @3000MHz (XMP on) Samsung 850 Evo

sp614x commented 5 years ago

Should be fixed in E5_pre2.

Cyphall commented 5 years ago

As stated above, it was already not happening on 1.13, it was more about if you still update the 1.12 version because it is a big mods version or anything else.