summaryrefslogtreecommitdiff
path: root/guix/packages.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2018-01-18 16:14:06 +0100
committerLudovic Courtès <ludo@gnu.org>2018-01-18 16:14:06 +0100
commit8102cf0b37e100f760d25b500cf91ed38928615c (patch)
treea0304a1298275e7dba0dc8298f5085271737a00d /guix/packages.scm
parente80514bc03b003a7ce95d7b55cf33c9f18f9e860 (diff)
downloadgnu-guix-8102cf0b37e100f760d25b500cf91ed38928615c.tar
gnu-guix-8102cf0b37e100f760d25b500cf91ed38928615c.tar.gz
gnu: commencement: Memoize 'linux-libre-headers-boot0'.
Fixes <https://bugs.gnu.org/30155>. The effect can be seen in the package graph produced by: guix graph -e '(@@ (gnu packages commencement) static-bash-for-glibc)' This reduces the number of "duplicate" nodes in this graph, i.e., distinct package objects that correspond to the same derivation (objects that are not 'eq?' but semantically equal.) * gnu/packages/commencement.scm (linux-libre-headers-boot0): Make an 'mlambda' instead of a 'lambda'. (hurd-core-headers-boot0): Ditto.
Diffstat (limited to 'guix/packages.scm')
-rw-r--r--guix/packages.scm3
1 files changed, 3 insertions, 0 deletions
diff --git a/guix/packages.scm b/guix/packages.scm
index 9571565e17..be0a5eeedb 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -620,6 +620,9 @@ itself.
This is implemented as a breadth-first traversal such that INPUTS is
preserved, and only duplicate propagated inputs are removed."
(define (seen? seen item outputs)
+ ;; FIXME: We're using pointer identity here, which is extremely sensitive
+ ;; to memoization in package-producing procedures; see
+ ;; <https://bugs.gnu.org/30155>.
(match (vhash-assq item seen)
((_ . o) (equal? o outputs))
(_ #f)))