diff options
author | Ludovic Courtès <ludo@gnu.org> | 2019-11-09 21:32:41 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2019-11-09 23:04:14 +0100 |
commit | 2a4309de43011f87b3a5044c3d956c261ae151e4 (patch) | |
tree | 8919ab75249b34e4bc50c000b914f005c0ca3901 /etc | |
parent | f0034427f50be1bcab137d9877c3586e4be4d83e (diff) | |
download | guix-2a4309de43011f87b3a5044c3d956c261ae151e4.tar guix-2a4309de43011f87b3a5044c3d956c261ae151e4.tar.gz |
services: 'fold-services' memoizes service values.
Previously 'fold-services' could end up traversing the same services in
the graph several times, which is what this change addresses.
The hit rate on the 'add-data-to-store' cache goves from 9% to 8% on
"guix system build desktop.tmpl -nd", and the number of lookups in that
cache goes from 4458 to 4383.
* gnu/services.scm (fold-services): Turn 'loop' into a monadic procedure
in %STATE-MONAD and use it to memoize values of visited services.
Diffstat (limited to 'etc')
0 files changed, 0 insertions, 0 deletions