Cool VL Viewer forum http://sldev.free.fr/forum/ |
|
New Cache http://sldev.free.fr/forum/viewtopic.php?f=5&t=2133 |
Page 1 of 1 |
Author: | Amalia Illios [ 2021-03-06 12:53:07 ] |
Post subject: | New Cache |
Hello Henri et al., is it just me or is that new "simple" cache blazingly fast compared to the old one? ![]() Regards, Lia |
Author: | Henri Beauchamp [ 2021-03-06 13:18:21 ] |
Post subject: | Re: New Cache |
I did not notice any "blazing" effect here (under Linux), but admittedly I'm already using a RAM disk for the viewer cache directory... It however certainly removes code bloat (*) from the viewer and thus speeds up cached asset files read/write. (*) i.e. a totally useless code, since a VFS brings no advantage whatsoever. I suppose it was initially adopted as a mean to obfuscate cached files and make ripping them "harder" but, as always, security via obscurity is inefficient and ultimately fails to reach its goal. |
Author: | Amalia Illios [ 2021-03-06 15:07:02 ] |
Post subject: | Re: New Cache |
Linux here as well, with an NVME SSD. Judging from the texture stats overlay, initial write to cache seems to be taking significantly less time now. Not having ever looked at the code but only the aforementioned stats overlay ... is texture loading handled similarly to web browser caching, i.e. with a modification checking before using cache content? If so, wouldn't that be counterproductive, considering that textures in SL technically can never change? I always pondered trying to set up a local transparent proxy for SL assets and textures to see how much that might speed things up, but admittedly never did it because lazy. ![]() Regards, Lia |
Author: | Henri Beauchamp [ 2021-03-06 16:25:34 ] | |||||||||||||||||||||||||||
Post subject: | Re: New Cache | |||||||||||||||||||||||||||
This has nothing to do with textures (excepted when uploading them). That cache is used by most assets (animations, sounds, scripts, note-cards, gestures, wearables, meshes, etc) but not for textures used for rendering, which are still held in the textures cache. Other caches are the objects cache (which caches objects parameters for each visited sim) and the inventory cache (which only caches the inventory items tree, but not any asset those items point at). I did improve a bit textures fetching speed in the former release however, by avoiding the recourse to textures cache locking when the textures console or viewer stats retrieve the number of textures being fetched. As for using a local proxy, you would probably be disappointed by the result. Better increasing your viewer cache size and/or storing the latter on a RAM disk (which contents is saved on OS shutdown and restored on reboot). Here is my (SysVinit, i.e. it is /etc/rc.d/init.d/ramdisk for me: not sure how the shitty systemd would handle that on non-sysv-init systems) script for my Linux PCs:
And in /etc/fstab I got the following entry for the RAM disk (here set for 12Gb max for a 64Gb RAM system):
Once you enabled and started the ramdisk service (e.g. for sysv-init: chkconfig --add ramdisk;service ramdisk start) you can move cache_coolvlviewer/ from ~/.secondlife/ to the RAM disk and replace it with in ~/.secondlife with a link to it:
From now on, the viewer will use the RAM disk automatically, and the latter will automatically be saved/restored on reboots. Another advantage of using a RAM disk for the viewer cache is that it spares many writes on your SSD, prolonging its life... |
Author: | ZaneZimer [ 2021-03-06 18:32:19 ] |
Post subject: | Re: New Cache |
I found a project that makes the set up pretty straightforward on platforms with systemd and npm. It's located at: patrikx3 /ramdisk. I've got it set up and it seems to be working well in my 32Gb system with a ramdisk size of 8Gb. |
Author: | Jessica Hultcrantz [ 2021-03-07 14:46:57 ] |
Post subject: | Re: New Cache |
I have no statistics to share, but I thought to chime in anyway. The visual experience for me is a noticeably faster rendering of items inworld with the new cache in place. Houses, boats, structures, ... that kind of things. (And that is with a regular spinning hard drive, no such speedy hardware as SSD's here yet ![]() Thanks Henri ^^ |
Author: | Henri Beauchamp [ 2021-03-07 14:48:17 ] | |||||||||
Post subject: | Re: New Cache | |||||||||
|
Author: | kathrine [ 2021-03-09 00:20:40 ] |
Post subject: | Re: New Cache |
It feels faster at least. I wonder if that could would benefit from some io_uring or Windows IOCP goodies, especially on NVMe SSDs. It looks much cleaner with the useless cruft removed. |
Author: | Henri Beauchamp [ 2021-03-09 12:20:06 ] | |||||||||
Post subject: | Re: New Cache | |||||||||
|
Page 1 of 1 | All times are UTC |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |