Re: [PATCH] Pick rest argument values directly from the argvector without consing

2019-10-27 Thread felix . winkelmann
Hi! Very cool, Peter. Please let me have a look at this before we seriously consider adding the patch. felix

Re: [PATCH] Pick rest argument values directly from the argvector without consing

2019-10-27 Thread Peter Bex
On Sun, Oct 27, 2019 at 04:22:58PM +0100, Jörg F. Wittenberger wrote: > Likely. Though I've seen graphics code, which had a huge amount of keyword > args. Will this change speed them up too? No, keyword arguments are basically handled as plists. It might be possible to translate this to some sort

Re: [PATCH] Pick rest argument values directly from the argvector without consing

2019-10-27 Thread Jörg F . Wittenberger
Thanks Peter for investing your time into this. While I did not proof-read your code, my bet is that this kind of optimizations do add up at the end of the day. On Oct 27 2019, Peter Bex wrote: On Sun, Oct 27, 2019 at 01:16:10PM +0100, Peter Bex wrote: This super simple benchmark runs 25% f

Re: [PATCH] Pick rest argument values directly from the argvector without consing

2019-10-27 Thread Peter Bex
On Sun, Oct 27, 2019 at 01:16:10PM +0100, Peter Bex wrote: > This super simple benchmark runs 25% faster with -O3: > > (define (foo #!optional (a 1) (b 2)) > (+ a b)) > > (time > (let lp ((i 0)) > (unless (= i 1) > (foo 1 3) > (lp (add1 i) I've tested some more, a

[PATCH] Pick rest argument values directly from the argvector without consing

2019-10-27 Thread Peter Bex
Hi all, Here's my patch for https://bugs.call-cc.org/ticket/1623. The commit message should provide sufficient details to understand what it does, I hope. This super simple benchmark runs 25% faster with -O3: (define (foo #!optional (a 1) (b 2)) (+ a b)) (time (let lp ((i 0)) (unless (=