[Ecls-list] Proclaims and compiler
Gabriel Dos Reis
gdr at integrable-solutions.net
Sun Mar 28 19:03:08 UTC 2010
On Sun, Mar 28, 2010 at 1:23 PM, Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> wrote:
> On Sun, Mar 21, 2010 at 4:03 PM, Waldek Hebisch <hebisch at math.uni.wroc.pl>
> wrote:
>>
>> Apparently optimize proclaims made before loading compiler
>> are ignored:
>>
>> (proclaim '(optimize (speed 3) (safety 0)))
>> (compile-file "call-spd.lisp")
>>
>> compiles "call-spd.lisp" at default safety. This is old
>> problem, still present in fresh git checkout.
>
> I do not think this is a "problem" by itself. It depends on your
> expectations.
> The default image of ECL only contains a function, PROCLAIM, that does
> nothing. This is compatible with the specification and works just fine with
> the interpreted code, source files, etc. It is there because it may appear,
> but does not force the user to load the compiler.
> When the compiler is loaded, it installs a new version of PROCLAIM that
> actually uses the information that this function provides. This function is
> more complete, but it can not exist without the compiler because there is no
> notion of compiler environment before the compiler itself is loaded.
> Note that we can not force the compiler to be loaded by a mere use of
> PROCLAIM. That would prevent the Lisp interpreter from loading perfectly
> valid sources that use PROCLAIM but do not compile anything.
> Juanjo
Hi Juanjo,
Proclamation is used a lot by OpenAxiom in the hope of helping the
Lisp compiler
generate more efficient code.
The way it is used by OpenAxiom is schematized by Waldek's example.
And it works
well with CLisp, SBCL, and GCL. For us, it is important that it works
well with ECL
too. Given the above explanation, how what is your recommendation to get the
proclamation used by the compiler? Is there a way to 'preload' the compiler
persistently in the preliminary 'lisp' image that we build prior to the Boot
translator?
-- Gaby
More information about the ecl-devel
mailing list