Quick question regarding indirection cells...

Marco Kesseler mke@oce.nl
Tue, 27 Jan 1998 17:18:05 +0100


>> Pehaps they do, but note that the Clean implementation avoids
>> generating indirection nodes alltogether. Nodes get overwritten
>> by their result, not by indirections to it.
>
>What happens when the overwiting structure is bigger than
>the cell to be overwritten?  (Assumptions: an application cell
>is a fixed size, and a constructor cell has at least one pointer
>for each field of the constructor.)   -- P

Hi Philip,

of course things are more complex than they seem.
Even (or especially?) in Clean.

To answer your question:
- application cells have some minimum size
- constructors cells larger than this minimum size are split
  in two parts. The first (small) part refers to the rest
  of the constructor. Application cells get overwritten by
  the first part of a constructor.

So, large conctructors do contain indirections... This however
is not quite the same as having indirection nodes. For example:
one never needs to traverse an indirection node before starting a
match.

---------------------------------------------

Marco Kesseler
Oce-Technologies B.V.
St. Urbanusweg 43, Venlo, The Netherlands
P.O. Box 101, 5900 MA Venlo, The Netherlands
telephone +31 77 359 5158
fax       +31 77 359 5450
e-mail    mke@oce.nl