[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: SUN vs Lisp machine hardware differences?
Date: Tue, 11 Aug 87 17:38 EDT
From: Daniel L. Weinreb <DLW@ALDERAAN.SCRC.Symbolics.COM>
Date: Tue, 11 Aug 87 13:54:26 PDT
From: larus%paris.Berkeley.EDU@berkeley.edu (James Larus)
Cdr-coding was proposed and justify in the mid-1970's when memory
prices and programs were quite different. I don't believe that the
original asssumptions hold true any long. If Symbolics has evidence
that this optimization is worth the complexity, then I and a number of
other people would be very interested in seeing it.
Of course it depends a lot on the time cost of dealing with cdr-coding,
on how much memory costs, on how much memory your program needs, and
which program you're running, and how much of your data structure is
lists versus non-lists, and how many references are to lists (do you
make a whole lot of big lists that you rarely refer to, or the
opposite), and so on. There are other issues here that are really too
complex to go into in detail. No, I don't know of any explict attempts
to do these measurements lately.
Just because I haven't seen them discussed on this list, let me point
out a couple advantages of cdr-coding:
1. For all operations but RPLACD, operations on cdr-coded lists need be
no slower than the equivalent operations on normally-coded lists. On
many architectures individual operations are slower because designers
didn't think additional complexity was worth putting into hardware for
2. On machine architectures which can pipeline memory reads, cdr-coding
is much faster for many operations such as searching a list (MEMBER,
CDDR). In normally-coded lists, memory reads cannot be pipelined since
the cdr address is unknown until it is read.
3. Cdr-coding significantly enhances paging performance with its data
compaction. Just as "files tend to fill up available file space",
programs and data tend to fill up available physical memory.
6 years ago lisp machines commonly had 128K words of memory, and today
they commonly have 2MW. Paging is no less a consideration today, nor do
I see that changing in the forseeable future. (Granted, this is an
assumption you can argue with.)
As usual, I will agree that for architectures with no hardware support,
cdr-coding is a bad idea.