[net.micro] stack growth w/o instr restart

ecn-pa.bruner (07/31/82)

One can implement dynamic stack growth via paging without being able
to restart aborted instructions.  Map unallocated pages to the same
"free" page in memory and set the memory management hardware to
generate an interrupt when a read/write occurs in this area (e.g.
when the stack grows downward into an "unallocated" page).  Rather
than aborting the "fault"-generating instruction in the middle,
allow it to complete (since it is reading/writing "real" memory),
and then (after it is done) an interrupt will occur.  Presumably the
MMU hardware will tell you the page that generated the fault.  If it
is above the SP, allocate the page and map another "free" page into
all of the "unallocated" slots.  If it is below the SP, generate a
segmentation violation signal and blow the process away.

A possible problem is a write onto a set of locations that cross a
page boundary.  If no uninterruptable instructions can write more than
a page-size's worth of bytes at once, then this problem can be solved
by using two "real" pages and mapping successive virtual pages to
alternate real ones.

--John Bruner