Ver 5.2 serious memory leak

I found a very serious memory leak bug in version 5.2. The steps to reproduce the bug are as follows:

Create a new empty project, create a new level, then save the level, set the level as the default map, and then pack it. Run the packaged application. In the resource manager, you can see that the memory of this application is constantly growing and will not stop. The program does not respond until the memory limit is reached.

I have reproduced this bug on more than one computer. Versions are currently limited to 5.2.0 and 5.2.1. I tried using version 5.0.3, without this problem.

The solution I have explored for this problem is: import a third-person template, and then change the gamemode to BP_ThirdPersonGameMode. But this is not a very good solution. Because in actual use, we often need to rewrite GameMode ourselves. Using the GameModeBase that comes with the system cannot solve this problem, nor can inheriting GameModeBase.

I found this BUG in my own project, and then I kept stripping out the interference items, and finally simplified the problem to the above steps. Hope someone can see what could be causing this. It should be a BUG that comes with Unreal Engine.

Hey there @MichaelCash! This memory leak has been reported, from what has been gathered it seems to stem from the Epic Games Web Helper subprocess and it’s somewhat inconsistent among users.

I’ve been trying to find an environmental correlation between users so may I ask a couple of questions?

May I know your specs?

This applies to all projects correct?

How long on average do you have to remain in editor before the memory bloat becomes bad?

My computer system is win11, but this BUG is also reproduced on win10. The memory is 128G, the graphics card is 3080ti, and the CPU is i9-12900K.
Almost all projects will have this problem, unless you use the BP_ThirdPersonGameMode of the engine’s default third-person template
In addition, will this problem be related to the time spent in the editor? I haven’t calculated it. In the process of groping for this problem, I have been stuck in the editor for a long time and a short time.

You can reproduce this bug by following the steps I said. This bug is easy to reproduce.

Absolutely understandable! I haven’t found a solid workaround in the meantime, but the more clear reports we can compile will definitely give the team a better idea of exactly what’s going on.

So if at all possible, could you submit the details in a full bug report?

This bug also affect mobile!!

Please check this out

https://forums.unrealengine.com/t/ue5-1-1-5-2-serious-mobile-performance-bug-must-be-noted-right-now/

So you are saying if we use the third person template the issue will be solved?

Unfortunately, this solution doesn’t work either. Originally I thought that using the BP_ThirdPersonGameMode of the third person template would solve this problem. But today I found out that this only increases memory for the first five minutes after running the program. Wait for 5 minutes without doing any operation, and the memory will start to grow crazily after 5 minutes.

Same, I tried with the third person game mode and it did not fix my issue. did you find any soultions yet? do you have discord??

You might want to check out this post

A temporary workaround for this problem
[/Script/Engine.RendererSettings]
r.gpucrash.collectionenable = 0

Oh a workaround has been found! Thanks for letting us know! @MichaelCash You should give this a try!

Where i can find that ini file? in engine folder or project folder?

I’ve tried this, but it doesn’t solve the problem.
Version 5.3, released on June 6, solves this problem.

1 Like

Didn’t work for me. Copied this command in my DefaultEngine.ini file just as you said but nothing happened.

It seems that the command itself mitigates the issue by limiting the crash reporter, but doesn’t stop the underlying issue but often drastically reduces how fast the memory leak builds. It’s recommended that if your project supports it to upgrade to 5.3 as that specific bug was fixed.

1 Like

Not only the memory leak but UE stalls a lot. Is happening very frequently. Wasn’t there in 5.0.3
It stalls on stuff as basic as renaming a var or deleting a node. Or even compiling simple blueprints.

I can update to 5.3 but Idk about the Lumen etc Performance and Not sure about metahumans. Would I have to redownload the Metahumans again for 5.3 ? or will the 5.2 ones that are installed would work in 5.3 if I update my project.?

I don’t often work with Metahumans, but I believe unless they had a major update between versions you should be able to upgrade the project and retain everything you had before. One thing that is more in question is that the new features for Metahumans in 5.3 if they are compatible with earlier metahumans or if you won’t be able to use them without downloading an updated MH.

I’d recommend backing your project up, upgrading a copy and give it a shot just as a performance and MH test.

1 Like

From what I could search on the web, the major revision was from 5.1 to 5.2+ so any project running 5.1 or earlier would need to upgrade to new ones.
I did that in my MH_Creator when I upgraded to 5.2
So hopefully they’ll not require any re-download.
And yeah, I have nothing to loose. So, as I’m writing this, I’m downloading 5.3.1 in the background and will duplicate my current project and test it out.

Thanks.

Fantastic. I’m interested in knowing how it goes, as this is a question I’d not yet considered due to the whole not using metahumans often.

1 Like