Article View: comp.lang.functional
Article #364Re: GC triggering and stack limit checking by MMU hardware
From: Allen Leung
Date: Fri, 20 Jul 1990 01:03
Date: Fri, 20 Jul 1990 01:03
31 lines
1975 bytes
1975 bytes
In article <1990Jul19.151524.22544@diku.dk> torbenm@diku.dk (Torben [gidius Mogensen) writes:
>
>Most implementations (that I know) of programming languages with
>stacks or heaps, use some kind of explicit check to see when a stack
>or heap is full. This is used to trigger events such as error
>messages, garbage collection or allocation of more memory for a
>fragmented stack. Usually, good implementations avoid testing on every
>use of the stack / heap, but only once for every basic block or
>procedure.
>
>By using the MMU facilities present in most modern computers, these
>tests can be entirely done in hardware, and fragmented stacks can be
>done transparently. This is the idea:
> [delete]
>My question is: has this been done? And if not, why not?
If I remember correctly, earlier version of Standard ML compiler
from New Jersey uses a very similar idea of using virtual address fault
to trigger garbage collection( if I read you correctly, this is what you are
describing.) This scheme was eventually abandoned
in favor of the explicit test due to problems with restarting an instruction
on the 680x0 after the fault. Also, this method does not port easily to
OSs other than Unix( or even to different versions of Unix).
I suspect using virtual memory to fault to gc is in general
a rather old trick.
> Torben Mogensen (torbenm@diku.dk)
Cheers,
Allen Leung (allen@sbcs.sunysn.edu)
Technical Details
Message-ID:
<1990Jul20.010305.27654@sbcs.sunysb.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!rutgers!cmcl2!sbcs!sbstaff2!allenReferences:
<1990Jul19.151524.22544@diku.dk>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!rutgers!cmcl2!sbcs!sbstaff2!allen From: allen@sbstaff2.cs.sunysb.edu ( Allen Leung) Newsgroups: comp.lang.functional Subject: Re: GC triggering and stack limit checking by MMU hardware Keywords: GC, stack, heap, MMU Message-ID: <1990Jul20.010305.27654@sbcs.sunysb.edu> Date: 20 Jul 90 01:03:05 GMT References: <1990Jul19.151524.22544@diku.dk> Sender: usenet@sbcs.sunysb.edu (Usenet poster) Organization: State University of New York at Stony Brook Lines: 31