It uses the LLVM JIT to compile and execute code on the fly in an
interpreter-like environment, and can also batch-compile code to native
executables. This includes the deterministic (non-backtracking) tree
matching automata needed to implement general term rewriting in an
efficient manner.
How good is LLVM for this?
There haven't been any other implementations of Pure compilers so that I
can't give you a real comparison. What I can say with confidence is that
LLVM made developing a code generator for Pure very convenient, because
of the readily available optimization passes, cross-platform support and
the integrated JIT.
E.g., is it natural to expect that the LLVM-based implementation of the
language Concurrent Clean be any faster than its reference implementation?
are there any attempts to use LLVM in graph-rewriting (term-rewriting)
language implementations?
I've added a new LLVM backend to the ghc Haskell compiler.
How good is LLVM for this?
Works very well. I'm operating from the low levels of the ghc compiler
though where I don't need to deal with the complexity of compiling a
functional language. The input to my backend is an intermediate
language called 'Cmm' that basically a lower level C like language.
I've written a new paper about my experiences using LLVM with my
supervisor, Manuel Chakravarty that I'll be presenting in a few weeks
at the Haskell Symposium. You can grab it here: http://www.cse.unsw.edu.au/~davidt/papers.html