[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Offtopic: How to Design Programming Tests



> X-Authentication-Warning: fast.cs.utah.edu: majordom set sender to owner-plt-scheme@flux.cs.utah.edu using -f
> Date: Fri, 9 Feb 2001 18:25:48 -0500 (EST)
> From: Shriram Krishnamurthi <sk@cs.brown.edu>
> Content-Type: text/plain; charset=us-ascii
> Cc: rurban@x-ray.at, plt-scheme@fast.cs.utah.edu
> Sender: owner-plt-scheme@fast.cs.utah.edu
> Precedence: bulk
> 
> Michael Vanier wrote:
> 
> > I would imagine that cache size and performance makes a huge difference
> > here.  Iterating through a linked list tends to lead to jumping around in
> > memory, thus (potentially) causing a lot of cache misses.  Arrays are less
> > subject to this.  Thus one might say that current CPU and memory technology
> > favor imperative languages which use arrays a lot :-(
> 
> Michael, did you ever consider that lists tend to be allocated
> sequentially, and that a copying collector engenders contiguity?
> 
> Folks, please read Mark Reinhold's papers and thesis (PhD, MIT,
> 1993(?)).  He did all that work so we can avoid speculating.  And it's
> fascinating stuff, too.
> 
> Shriram
> 

I'll check it out.  Is the mzscheme collector a copying collector?
Glancing at the source code, it appears that the Boehm GC is not but the
alternate (precise) GC is.

Realistically, though, I suspect that performance in scheme has very little
to do with lists vs. arrays and much more to do with the overhead of
dynamic typing (and bytecode interpretation for implementations like
mzscheme).  Feel free to correct me if I'm wrong :-)  Since I'm interested
in mzscheme as a replacement for python, not C, this doesn't concern me
either.

Mike