On Thu 05 Aug 2010 18:21, Luca Saiu writes:
> Andy Wingo wrote:
>> The toplevel references to bitvector-set! don't get cached, so the
>> bitvector-set! gets looked up every time, and there is some unfortunate
>> allocation in scm_from_locale_symboln. If you put it in a function,
>> the variable g
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Andy Wingo wrote:
> The toplevel references to bitvector-set! don't get cached, so the
> bitvector-set! gets looked up every time, and there is some unfortunate
> allocation in scm_from_locale_symboln. If you put it in a function,
> the variable gets c
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hello.
Andy Wingo wrote:
> On Mon 29 Mar 2010 18:09, Luca Saiu writes:
>
>> To sum up, within each run the computation time of (fibo n) is the same,
>> but the time varies widely from one run to another. This anomaly seems
>> to have become much mor
Hi,
On Thu 05 Aug 2010 15:42, Luca Saiu writes:
> ;;; Why does this GCs after creating b? Try running this with
> GC_PRINT_STATS=1,
> ;;; or with GC_DONT_GC=1 if you want to see the memory use rise.
>
> (define size 10)
> (define times 100)
>
> (define b (make-bitvector size))
>
> (do ((t
On Mon 29 Mar 2010 18:09, Luca Saiu writes:
> To sum up, within each run the computation time of (fibo n) is the same,
> but the time varies widely from one run to another. This anomaly seems
> to have become much more accentuated in 1.9.
I suspect this is related to the GC issues brought up rec
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi Ludovic.
Ludovic Courtès wrote:
> Hello,
>
> Luca Saiu writes:
>
>> The effect is much weaker in either case, when using tail-recursive
>> functions. This is interesting.
>
> Another guess: it could be that the non-tail-recursive version fills
Hello,
Luca Saiu writes:
> The effect is much weaker in either case, when using tail-recursive
> functions. This is interesting.
Another guess: it could be that the non-tail-recursive version fills the
L2 cache (/sys/devices/system/cpu/cpu0/cache/index2/size says it’s 2 MiB
on my laptop), or so
Hi Luca,
Luca Saiu writes:
> (define (fibo n)
> (if (< n 2)
> n
> (+ (fibo (- n 1))
> (fibo (- n 2)
This function is not tail-recursive, so it consumes stack space, which
increases the amount of memory the GC has to scan. My guess is that
this has to do with the time