Notes for a talk.

Ralph Becket rwab1 at cam.sri.com
Thu Oct 30 23:33:04 AEDT 1997


Thanks to a bad case of evangelism in the pub, I've been asked to give
a talk on Mercury to the Systems Research Group at the University,
here.  The SRG is mostly concerned with machine architecture,
operating systems and networking.  Their language of choice is plain
old C because there's a very direct and obvious mapping between it and
the machine instructions the compiler generates.

I've had a look at the slides for the JICSLP talk Fergus and Zoltan
gave in 1996 and they compare gcc C against Mercury on the Uni. of
Montreal Pseudoknot benchmark: Mercury was a factor of 5.5 slower with
GC and 3.7 without.

I can sell Mercury's other virtues to these guys, but as they work so
close to the metal they're obsessed with efficiency.  What I'd like to
know is how far the gap has narrowed in the last year and what further
improvements are anticipated.  How much better would things get if
there was a native back-end for the compiler?  What about with a
dedicated garbage collector and full support for destructive
assignment?

Also, there's a lot of interest there about parallelising compilers
and I believe people are working on one for Mercury - can anybody give
me some information on this?

Finally, I recently saw a video by one of the guys who designed the
Alpha processor.  He showed that the cache assumption (that memory
reference i is a good indicator of memory reference i+1) was pretty
much shot to bits when running a C compiler and an SQL database server
and even for most of a standard benchmark suite.  His suggestion was
that compilers should attempt to spot rambling pointer based
structures and reduce them to more cache friendly arrays.  It seems to
me that Mercury would be the ideal language for this kind of
experimentation given that it's declarative and the compiler has
access to volumes of information about the program.  Anybody have any
thoughts on the matter that I could bring up?

Many thanks in advance for any help,

Ralph

-- 
Ralph Becket  |  rwab1 at cam.sri.com  |  http://www.cam.sri.com/people/becket.html



More information about the users mailing list