Performance of getkey & setkey
-
hermhart
- Posts: 259
- Joined: 13 Jan 2015 18:41
Re: Performance of getkey & setkey
Has anything changed in the way of being able to use getkey/setkey for reading/writing to what is currently in ram?
Windows 11 Pro; 100% scaling
-
admin
- Site Admin
- Posts: 67311
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
-
FluxTorpedoe
- Posts: 906
- Joined: 05 Oct 2011 13:15
Re: Performance of getkey & setkey
I just discover this old post !
So I thought I’d share my experience…
About five years ago (I don’t know which XYplorer version it was), I tried lots of way to optimize Session Manager the best I could.
One of them was exactly this idea : using getkey from a variable to limit access to disk. It wasn’t possible out of the box, so I made my own function.
FYI, Session Manager has (relatively) quite a lot to do and check each time it’s launched, including lots of getkey — especially for all translated strings. I just checked this old "prototype" version, and it had 73 occurrences of my custom getkey (even if not all were used each time).
So I activated timers (BTW, they’re still available in the script if you want to do some tests!), and made speed tests in different conditions, and with several variations using eitheir gettoken, regexmatches, etc.
And the results were…
Disappointing.
To say the least (regarding the time it took me to implement this custom getkey).
Not only wasn’t it faster but, if I remember correctly, I think some variations were quite slower…
(Note : I can’t guarantee it, but I think I tested it also from a regular HDD.)
So, there you have it. I know it’s a single opinion (and only from a scripting perspective), but at least my own conclusion was clear : not worth bothering.
Have a nice day,
Flux
So I thought I’d share my experience…
About five years ago (I don’t know which XYplorer version it was), I tried lots of way to optimize Session Manager the best I could.
One of them was exactly this idea : using getkey from a variable to limit access to disk. It wasn’t possible out of the box, so I made my own function.
FYI, Session Manager has (relatively) quite a lot to do and check each time it’s launched, including lots of getkey — especially for all translated strings. I just checked this old "prototype" version, and it had 73 occurrences of my custom getkey (even if not all were used each time).
So I activated timers (BTW, they’re still available in the script if you want to do some tests!), and made speed tests in different conditions, and with several variations using eitheir gettoken, regexmatches, etc.
And the results were…
Disappointing.
To say the least (regarding the time it took me to implement this custom getkey).
Not only wasn’t it faster but, if I remember correctly, I think some variations were quite slower…
(Note : I can’t guarantee it, but I think I tested it also from a regular HDD.)
So, there you have it. I know it’s a single opinion (and only from a scripting perspective), but at least my own conclusion was clear : not worth bothering.
Have a nice day,
Flux
Last edited by FluxTorpedoe on 07 Mar 2022 18:51, edited 1 time in total.
• Scripts: Session Manager
| SlideShow | Collection Manager | Power Launcher | Akelpad syntax highlighting | ...
-
hermhart
- Posts: 259
- Joined: 13 Jan 2015 18:41
XYplorer Beta Club