Bill Page wrote:
> 
> My second question also applies to OpenAxiom and I do not think it has
> been fully addressed there:  What is the underlying motivation for
> replacing Lisp with some other run time environment?

One aspect is speed: using SBCL we can get about half of C speed.
Lisp community is unlikely to have resources to build compiler
which optimizes as well as C compilers.  LLVM can generate
code into memory, giving us dynamically generated highly
optimized code (of course there is tradeoff between compilation
speed and speed of generated code).  Also, using LLVM means
much simpler interfacing to foreign libraries.

In principle Lisp compilers could adopt LLVM.  However, Lisp
sematics is mostly untyped.  Spad is strongly typed and we
want to take advantate of types when generating code.
With Lisp we need Lisp compiler which can make good use
of declarations present in output of Spad compiler.
SBCL is doing relatively good job with types, ECL not
so good.  In case of ECL backend is very strong but
ECL limits possible speed.  In case of SBCL backed
is weaker...  For SBCL adopting LLVM as backend would
be quite hard.  For ECL would be much easier, but we
would get little effect.  To put it differently,
interfacing directly to stronger backend we can
get better speed at moderate effort.  Going via Lisp
means extra work.

Note that Aldor generates C, which has some limitations.
LLVM potentially has advantages like generating code
to memory, exception support, garbage collection
support.  Let me add that this is applied software
research: software is developed and then we look
how much effort it took and how well it performs.
Of course we try to take promising directions, but
ultimately only when software is done we know its
merits.  In case of LLVM backend that Krystian
developed, it can generate quite good code when
types are simple and known.  Much better than
typical SBCL code.  But Spad compiler forgets
type information immediately after having generated
code for given construct.  Krystian modified
Spad compiler to store part of type information,
but what we get is still incomplete.

-- 
                              Waldek Hebisch
[email protected] 

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to