Shall we drop resources ?

Jean-Marc Lasgouttes lasgouttes at lyx.org
Thu May 14 18:42:49 UTC 2020


Le 14/05/2020 à 18:16, Jean-Marc Lasgouttes a écrit :
> I only noticed now that Resources have been made useless just 3 days 
> after there were introduced  at 33e397dff8792c.
> 
> This is the result of this thread:
> https://marc.info/?l=lyx-devel&m=119283257516050&w=2
> 
> What I do not understand is why André did not complain more a the time. 
> As it is now, resources are never used, since the filesystem is looked 
> at first.

On a SSD drive (after a reboot), launching lyx creating an empty formula 
and quitting leads to the following timing for the iconName() function 
alone.

tanuki: src/lyx
#pmprof# iconName: 180.96 us, count=235, total=42.52 ms

If I remove the search in the file system (and thus force use of 
resource), I get:

tanuki: src/lyx
#pmprof# iconName: 13.96 us, count=234, total=3.27 ms

So, using resources is 15x faster, but the total time of 40ms is barely 
noticeable.

What would be interesting though is to try that on an older computer 
with mechanical hard drive. Is there someone with such a disabled machine ?

JMarc

> I see 3 possibilities:
> 
> 1/ get rid of resources, since nobody complained that we were too slow 
> up to now.
> 
> 2/ do not install  anything in lib/images/ directory, since it is in 
> resources already.
> 
> 3/ look first at user directory, then resources and finally system 
> directory.
> 
> 
> What shall we do about that?
> 
> JMarc



More information about the lyx-devel mailing list