unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* Re: [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.2-100-g40bd6a7
       [not found] <E1R6Gn9-00006v-Fs@vcs.savannah.gnu.org>
@ 2011-09-21  9:13 ` Ludovic Courtès
  2011-09-21 10:26   ` Andy Wingo
  0 siblings, 1 reply; 3+ messages in thread
From: Ludovic Courtès @ 2011-09-21  9:13 UTC (permalink / raw)
  To: Andy Wingo; +Cc: guile-devel

Hi Andy,

Thanks for polishing peval!

"Andy Wingo" <wingo@pobox.com> skribis:

> commit 4f33b47591e823500d800ee4f9d98c8ae98ceab8
> Author: Andy Wingo <wingo@pobox.com>
> Date:   Wed Sep 21 08:58:09 2011 +0200
>
>     peval: inlining of let-values
>     
>     * module/language/tree-il/optimize.scm (peval): Add support for
>       let-values.  Try to inline the consumer into the body of the producer,
>       if there is only one return point, and we can figure out how many
>       values are being returned, and that number is compatible with the
>       consumer.
>
> commit 65a32655253cdfcf4e2caf03a73ac66b05da5f71
> Author: Andy Wingo <wingo@pobox.com>
> Date:   Wed Sep 21 08:56:09 2011 +0200
>
>     peval support for more forms
>     
>     * module/language/tree-il/optimize.scm (peval): Add support for fix,
>       dynwind, dynlet, dynref, module-set, and toplevel-set.  (Mutating a
>       variable directly is similar to calling a function that does so behind
>       our backs, so this presents no additional problem.)

I believe that at least the <let-values> and <fix> cases are dead code
since ‘fix-letrec!’ hasn’t been called at the point ‘peval’ is called.
No?

Also, could you add tests for the new cases handled?  :-)  It’d make it
easier for me to follow, and would help us not break it later.

Thanks,
Ludo’.



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.2-100-g40bd6a7
  2011-09-21  9:13 ` [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.2-100-g40bd6a7 Ludovic Courtès
@ 2011-09-21 10:26   ` Andy Wingo
  2011-09-21 12:26     ` Ludovic Courtès
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Wingo @ 2011-09-21 10:26 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: guile-devel

Hi,

On Wed 21 Sep 2011 11:13, ludo@gnu.org (Ludovic Courtès) writes:

> I believe that at least the <let-values> and <fix> cases are dead code
> since ‘fix-letrec!’ hasn’t been called at the point ‘peval’ is called.
> No?

For <fix>, perhaps it should be called earlier.  The `let-values' case
is explicitly handled by an inlining of @call-with-values to let-values
in peval, with the goal of removing the later inlining pass, as it's not
as good as peval.

> Also, could you add tests for the new cases handled?  :-)  It’d make it
> easier for me to follow, and would help us not break it later.

I can try, when I have some time.  Though, to disseminate the
understanding as widely as possible, perhaps I shouldn't be the one to
write those tests ;)

Andy
-- 
http://wingolog.org/



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.2-100-g40bd6a7
  2011-09-21 10:26   ` Andy Wingo
@ 2011-09-21 12:26     ` Ludovic Courtès
  0 siblings, 0 replies; 3+ messages in thread
From: Ludovic Courtès @ 2011-09-21 12:26 UTC (permalink / raw)
  To: Andy Wingo; +Cc: guile-devel

Hi,

Andy Wingo <wingo@pobox.com> skribis:

> On Wed 21 Sep 2011 11:13, ludo@gnu.org (Ludovic Courtès) writes:
>
>> I believe that at least the <let-values> and <fix> cases are dead code
>> since ‘fix-letrec!’ hasn’t been called at the point ‘peval’ is called.
>> No?
>
> For <fix>, perhaps it should be called earlier.  The `let-values' case
> is explicitly handled by an inlining of @call-with-values to let-values
> in peval, with the goal of removing the later inlining pass, as it's not
> as good as peval.

I see, thanks!

Ludo’.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-09-21 12:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <E1R6Gn9-00006v-Fs@vcs.savannah.gnu.org>
2011-09-21  9:13 ` [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.2-100-g40bd6a7 Ludovic Courtès
2011-09-21 10:26   ` Andy Wingo
2011-09-21 12:26     ` 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).