Nala Ginrut skribis:
> And there're two possible applications:
> 1. handle the requests in a server
> 2. read files from disk (but how big file is proper for par-map)
Quoting the fine manual:
Note that futures are intended for the evaluation of purely
functional expressions. Expressions th
On Thu, 2013-03-28 at 01:05 -0400, Mark H Weaver wrote:
> Nala Ginrut writes:
>
> > But I'm still puzzled with the performance of par-map:
> > cut---
> > scheme@(guile-user)> ,time (define a (map (lambda (x) (expt x 5)) (iota
> > 1)))
> > ;; 0.008019s real
Mark H Weaver skribis:
> l...@gnu.org (Ludovic Courtès) writes:
>
>> Mark H Weaver skribis:
>>
>>> It only makes sense to use 'par-map' when the procedure is fairly
>>> expensive to compute.
>>
>> Indeed.
>>
>>> There is inevitably a lot of overhead in creating and joining the
>>> threads.
>>
>>
Hi Ludovic,
l...@gnu.org (Ludovic Courtès) writes:
> Mark H Weaver skribis:
>
>> It only makes sense to use 'par-map' when the procedure is fairly
>> expensive to compute.
>
> Indeed.
>
>> There is inevitably a lot of overhead in creating and joining the
>> threads.
>
> We use a thread pool, so
Mark H Weaver skribis:
> Nala Ginrut writes:
>
>> But I'm still puzzled with the performance of par-map:
>> cut---
>> scheme@(guile-user)> ,time (define a (map (lambda (x) (expt x 5)) (iota
>> 1)))
>> ;; 0.008019s real time, 0.007979s run time. 0.00s
Nala Ginrut writes:
> But I'm still puzzled with the performance of par-map:
> cut---
> scheme@(guile-user)> ,time (define a (map (lambda (x) (expt x 5)) (iota
> 1)))
> ;; 0.008019s real time, 0.007979s run time. 0.00s spent in GC.
> scheme@(guile-user
On Wed, 2013-03-27 at 18:12 +0100, Ludovic Courtès wrote:
> Hi,
>
> Nala Ginrut skribis:
>
> > scheme@(guile-user)> (par-map 1+ (iota 1))
> > While executing meta-command:
> > ERROR: Throw to key `vm-error' with args `(vm-run "VM: Stack
> > overflow" ())'.
>
> Commit 8a177d3 fixes this. I
Hi,
Nala Ginrut skribis:
> scheme@(guile-user)> (par-map 1+ (iota 1))
> While executing meta-command:
> ERROR: Throw to key `vm-error' with args `(vm-run "VM: Stack
> overflow" ())'.
Commit 8a177d3 fixes this. I added a paragraph in the documentation
that explains what happens: delimited c
Here is the error message.
Anyway, par-map shouldn't cause stack overflow.
---err msg--
scheme@(guile-user)> (par-map 1+ (iota 1))
While executing meta-command:
ERROR: Throw to key `vm-error' with args `(vm-run "VM: Stack
overflow" ())'.