From: Andy Wingo <wingo@pobox.com>
Subject: problem with futures?
Date: Wed, 21 Dec 2005 17:10:13 -0500 [thread overview]
Message-ID: <1135203013.4312.40.camel@localhost.localdomain> (raw)
Hi,
With current CVS on PPC (because I still haven't investigated enough to
figure what's wrong on x86-64),
(define (nsum n)
(apply + (let ((x 1))
(par-map (lambda (y) (set! x (1+ x)) (+ y x))
(make-list n 0)))))
I get this:
guile> (nsum 100)
$1 = 5150
guile> (nsum 100)
$2 = 5150
guile> (nsum 100)
$3 = 5150
guile> (nsum 100)
Backtrace:
In current input:
5: 0* [nsum 100]
1: 1 [apply #<primitive-generic +> ...
1: 2* (let* ((x 1)) (par-map (lambda (y) (set! x #) (+ y x))
(make-list n 0)))
1: 3 [par-map #<procedure #f (y)> (0 0 0 0 0 0 0 0 0 ...)]
In /opt/guile/share/guile/1.7/ice-9/threads.scm:
52: 4 [map #<primitive-procedure future-ref> ...
53: 5* [apply #<primitive-generic map> #<procedure #f args> ...]
In unknown file:
?: 6 [map]
?: 7* [map #<procedure #f args> (0 0 0 0 0 0 0 0 0 ...)]
?: 8* [#<procedure #f args> 0]
In /opt/guile/share/guile/1.7/ice-9/threads.scm:
55: 9* (future (apply mapper (proc . arglists)))
/opt/guile/share/guile/1.7/ice-9/threads.scm:55:20: In expression
(future (apply mapper #)):
/opt/guile/share/guile/1.7/ice-9/threads.scm:55:20: Cannot allocate
memory
>From then on out I can't call nsum any more. Perhaps threads assigned to
futures are not being gc'd properly.
Regards,
--
Andy Wingo
http://wingolog.org/
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-devel
next reply other threads:[~2005-12-21 22:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-21 22:10 Andy Wingo [this message]
2005-12-22 9:56 ` problem with futures? Mikael Djurfeldt
2006-01-29 18:44 ` Marius Vollmer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1135203013.4312.40.camel@localhost.localdomain \
--to=wingo@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).