PDP-11 stack size

utzoo!decvax!ucbvax!menlo70!sri-unix!dan at BBN-UNIX utzoo!decvax!ucbvax!menlo70!sri-unix!dan at BBN-UNIX
Thu Dec 31 21:57:56 AEST 1981


From: Dan Franklin <dan at BBN-UNIX>
Seems like a workable way to get those last few bytes. But you don't need to
change the u area to keep track of the "virtual" limit; the sbrk library
routine (!) already does that privately. Merely changing estabur to be willing
to map the whole address space is sufficient.

To detect collisions between the stack and data, you could use the stack limit
register, at least on the 11/45, 55, 60, and 70 (I don't know about the
others). It provides 256-byte resolution, which is better than nothing. Its
value would have to saved and restored across process switches. (This also
assumes that the stack limit register works in user mode, which I have never
had to verify.)



More information about the Comp.unix.wizards mailing list