chicken-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-hackers] [PATCH] slightly more optimistic copy-propagation


From: Peter Bex
Subject: Re: [Chicken-hackers] [PATCH] slightly more optimistic copy-propagation
Date: Sat, 29 Sep 2012 19:11:13 +0200
User-agent: Mutt/1.4.2.3i

On Sat, Sep 29, 2012 at 03:35:41PM +0200, Felix wrote:
> This patch improves copy-propagation in the compiler somewhat:
> 
> 1) If a variable is known to be bound to a global variable which
>    itself refers to an intrinsic function (one of the "standard-" or
>    "extended" bindings, that get specifically treated in call position
>    by the compiler), than references to the former variable will
>    be replaced with the latter.
> 
> 2) If a variable is bound to another variable that in "-local" mode
>    has a known value, then references to the former will be replaced
>    by the latter (this was previously done only for truely known
>    variables, regardless of "-local" mode).

The patch looks good to my untrained eyes, but for some reason it causes
the compiler to hang and burn CPU after it was recompiled with itself.
Try it: compile & install, make spotless, compile & install again, then
run "make check" or compile any Scheme file.

I guess the bootstrap process would give similar results.

Cheers,
Peter
-- 
http://sjamaan.ath.cx
--
"The process of preparing programs for a digital computer
 is especially attractive, not only because it can be economically
 and scientifically rewarding, but also because it can be an aesthetic
 experience much like composing poetry or music."
                                                        -- Donald Knuth



reply via email to

[Prev in Thread] Current Thread [Next in Thread]