* Back to the future!
@ 2010-12-02 23:55 Ludovic Courtès
2010-12-03 9:57 ` Andy Wingo
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Ludovic Courtès @ 2010-12-02 23:55 UTC (permalink / raw)
To: guile-devel
Hello!
There’s a brand new (ice-9 futures) module implementing futures:
http://git.sv.gnu.org/cgit/guile.git/commit/?id=0d4e6ca38f1c51f5f92effc7d97c8b69eb85d071
(There used to be an implementation of futures in libguile, but it was
never included in a release because of various bugs.)
It basically does the job, though there are a couple of minor FIXMEs or
TODOs.
The implementation was inspired by that of libgomp, the GNU OpenMP
run-time support library. It uses a pool of threads, normally one per
CPU core minus one, and offloads expression evaluation to them. On a
single-core machine, you get an empty thread pool, meaning that futures
are evaluated sequentially, upon ‘touch’.
Feedback welcome! :-)
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Back to the future!
2010-12-02 23:55 Back to the future! Ludovic Courtès
@ 2010-12-03 9:57 ` Andy Wingo
2010-12-05 16:59 ` Neil Jerram
2010-12-16 22:56 ` Ludovic Courtès
2 siblings, 0 replies; 5+ messages in thread
From: Andy Wingo @ 2010-12-03 9:57 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: guile-devel
On Fri 03 Dec 2010 00:55, ludo@gnu.org (Ludovic Courtès) writes:
> There’s a brand new (ice-9 futures) module implementing futures:
Cool!
Andy
--
http://wingolog.org/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Back to the future!
2010-12-02 23:55 Back to the future! Ludovic Courtès
2010-12-03 9:57 ` Andy Wingo
@ 2010-12-05 16:59 ` Neil Jerram
2010-12-07 14:04 ` Ludovic Courtès
2010-12-16 22:56 ` Ludovic Courtès
2 siblings, 1 reply; 5+ messages in thread
From: Neil Jerram @ 2010-12-05 16:59 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: guile-devel
ludo@gnu.org (Ludovic Courtès) writes:
> Hello!
>
> There’s a brand new (ice-9 futures) module implementing futures:
Cool. One thing I noticed:
> (set! %futures (cons future %futures)) ;; FIXME: use a FIFO
I believe (ice-9 q) provides FIFOs, so you could use that.
Neil
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Back to the future!
2010-12-05 16:59 ` Neil Jerram
@ 2010-12-07 14:04 ` Ludovic Courtès
0 siblings, 0 replies; 5+ messages in thread
From: Ludovic Courtès @ 2010-12-07 14:04 UTC (permalink / raw)
To: guile-devel
Hello!
Neil Jerram <neil@ossau.uklinux.net> writes:
> ludo@gnu.org (Ludovic Courtès) writes:
[...]
>> (set! %futures (cons future %futures)) ;; FIXME: use a FIFO
>
> I believe (ice-9 q) provides FIFOs, so you could use that.
Right. I’m not fond of its API, but we’ll see.
BTW, you might want to contemplate the restrictions of futures as
implemented by one of our competitor:
http://docs.racket-lang.org/guide/performance.html#%28part._effective-futures%29
Both ‘*’ and ‘/’ can be used in Guile futures! ;-)
Ludo’.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Back to the future!
2010-12-02 23:55 Back to the future! Ludovic Courtès
2010-12-03 9:57 ` Andy Wingo
2010-12-05 16:59 ` Neil Jerram
@ 2010-12-16 22:56 ` Ludovic Courtès
2 siblings, 0 replies; 5+ messages in thread
From: Ludovic Courtès @ 2010-12-16 22:56 UTC (permalink / raw)
To: guile-devel
Hello!
I rebased ‘parallel’, ‘par-map’, and ‘par-for-each’ on top of futures
(commit c21a5ddcaf2b17d65355c977f37ee50375961d17). The rationale is
documented in the same commit, with a recommendation against the ‘n-’
variants of these procedures.
Feedback welcome!
Ludo’.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-12-16 22:56 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-02 23:55 Back to the future! Ludovic Courtès
2010-12-03 9:57 ` Andy Wingo
2010-12-05 16:59 ` Neil Jerram
2010-12-07 14:04 ` Ludovic Courtès
2010-12-16 22:56 ` Ludovic Courtès
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).