Emulator Issues #11004
openNull video backend and OGL video backends become unbearably slow due to texture cache.
0%
Description
Game Name?
Super Smash Brothers Melee
The issue is present at the latest GitHub master as of April 15th. I've attached a profile using the Google perftools profiler of CPU usage after 10 minutes of play with the Null backend. With the OGL backend, it takes more like 24 hours to get the same result.
All the time is spent in FindMatchingTexturesFromPool in the line: auto range = texture_pool.equal_range(config);
It seems that the texture_pool is growing indefinitely causing performance issues. After more play, pretty much all of the CPU is spent on that line of code.
Files
Updated by vomjom over 6 years ago
I haven't yet confirmed that OGL is the exact same issue, but it has the same symptoms. I can confirm if needed, but I'll need to run it for another day.
Updated by degasus over 6 years ago
I think this one here is the affected call: https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/VideoCommon/TextureCacheBase.cpp#L1918
But the texture_pool should get cleaned after 3 frames: https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/VideoCommon/TextureCacheBase.cpp#L192
So this behavior is very strange.