-
Notifications
You must be signed in to change notification settings - Fork 318
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
Added a cache for skin filenames to improve EPG performance. #2928
base: master
Are you sure you want to change the base?
Added a cache for skin filenames to improve EPG performance. #2928
Conversation
resolveFilename is used all over the place and not only in graphical EPG. If you wanna have cache the you should cache the image itself in graphical EPG and not the filename. |
I restricted it to SCOPE_GUISKIN so it only caches the filenames of skin files. Skin files don't move around, do they? Taking 0.4-0.5 seconds just to find these files seems ridiculous. |
You probably miss one thing. This may kill low memory boxes. |
Maybe just turn caching on in places like opening the EPG, e.g. setResolveFilenameCaching(true) |
Can you please run your box for a while and open a lot of screens and plugins and then dump the content of your cache in the log or extra file. https://github.com/openatv/enigma2/blob/master/lib/python/StartEnigma.py#L938 Restart GUI will then call the dump |
Hi @dachaplin, we will do that differently by adding the cache into EPG. |
OK. Let me know if you still want the cache dump. |
You can post the dump. This will help us to find the files. |
Here's the dump. I opened most of the EPG screens, some settings screens, and a bunch of plugins. |
There is probably no way of knowing if a skin or plugin is programmatically changing the same image. |
I've been profiling opening the graphical EPG in MetrixHD (on a Zgemma H.2S) and noticed that a lot of time is spent in resolveFilename():
It is taking 0.432 seconds just to resolve filenames. With more rows in the EPG and using other skins this can go even higher (it was over 0.5 seconds for me, using Slyk Onyx with 16 rows).
I tried adding a cache of resolved filenames and this reduced the time considerably, especially once the cache is created after the first call to openGraphEPG():
I'm new to the Enigma code so I'm not sure if this will cause problems elsewhere, but hopefully something like this can be done.