generalized suspend wanted

budd at arizona.UUCP budd at arizona.UUCP
Tue Feb 28 06:11:20 AEST 1984


        The following problem seems conceptually easy, but subtle to
implement - before I consider it further - has anybody else done anything
similar?

        Generally speaking, the idea is to suspend a program and then
pick it up later, even if later is across login boundaries (three weeks
later, for example).  The general solution would be to hack the shell to
give you these capabilities.  Slightly less bothersome would be to
have some routine, eg, suspend_me, which when called produces a something
and then gracefully dies.  That something can somehow be
started up again, acting as if suspend_me returned and all was normal.
I originally thought suspend_me could produce a new a.out file, but
it appears one cannot initialize the stack and registers with that approach.
I believe suspend_me will have to produce a core dump, and to restart somethig
will have to rummage through that core dump and set everything up.  adb and
sdb do this using ptrace, which would mean creating a child in the image
that you would like, resetting the stack and malloc'ed
areas one word at a time, starting the child and going away.
- there must be an easier way.  Anybody have any leads?



More information about the Comp.unix.wizards mailing list