This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RTL/tree (from gcc) and Scheme


Valery A.Khamenya wrote:

I thought "GCC's" means "belongs to GCC" or "something of GCC".
Like "Father's car" :-)

Or in this case "part of GCC".


But let's assume you know the *real* definitions.

I know the real definitions used within the GCC community. Other compiler people may use slightly different terminology.

I am just wondering: R5RS has nothing to say about compilation. There
is even no any meaning for this.

That is because compilation is an implementation technique. A standard should not talk about implementation, only behavior. In fact what is "compilation" is quite ambiguous. In Java people refere to compilation both for compiling Java source to byte-code, as well as for compiling (either) to machine code.

Do you mean then that kawa make
compilation to run-time before *every* eval?!

Not every eval - just the non-trivial ones. It does not compile a function application - but it does compile a function definition, including lambda expressions and let expressions.

> it would be not that bad!

It's not bad at all - it works very well and fast.  The Kawa compiler
is quite fast, and it generates bytecode directly into memory, which
it loads using a ClassLoader.  So while the overhead is high compared
to just doing the evaluation, in practice it doesn't matter.  Of course
if you're calling eval on non-simple expressions inside an inner loop
then performance may suffer.  But that's a dumb thing to do if you
care about performance, so it doesn't matter.  I haven't measured
the overhead of using the compiler, but it is clearly "plenty fast
enough" that there is no point in maintaining a separate interpreter.

that's right. Trees and RTL are used for *compile-time* only now.
And here came my question: is it really *impossible* to change thing
and use RTL/tree in run-time?

Of course it's not impossible. But what's the point? What do you mean by "using RTL/tree at run-time"? What are you trying to do?

Some languages could take a new breath
just because of this exported service!

But you haven't explained what the "exported service" would be and what it would be used for.

BTW, Per, did you get a moment to take a glance at Bigloo?

I'm aware of it and have glanced at it. Bigloo is a nice Scheme implementation and compiler. Note that Kawa is more general, as it supports multiple programming langauges, including Emecs Lisp, XQuery, and Common Lisp (though the latter is too incomplete to be useful). -- --Per Bothner per@bothner.com http://per.bothner.com/



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]