[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#28784: 'guix publish' leaks memory

From: Ludovic Courtès
Subject: bug#28784: 'guix publish' leaks memory
Date: Wed, 11 Oct 2017 15:22:19 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)

address@hidden (Ludovic Courtès) skribis:

> On the build farms, memory usage of the ‘guix publish’ process increases
> slowly but indefinitely, it seems.

This program reproduced the problem:

--8<---------------cut here---------------start------------->8---
(use-modules (guix zlib)
             (ice-9 format)
             (rnrs io ports))

(define (display-heap-size)
  (format #t "heap size: ~,2h MiB~%"
          (/ (assoc-ref (gc-stats) 'heap-size) (expt 2. 20))))

(let loop ((i 0))
  (when (zero? (modulo i 1000))
  (let ((port (open-file "/dev/null" "w0")))
    (call-with-gzip-output-port port
      (lambda (port)
        (display (make-string 1000 #\a) port))))
  (loop (+ 1 i)))
--8<---------------cut here---------------end--------------->8---

This is fixed in 85a2b58987bc32e33e63bea86c1a94496b796ae9.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]