[comp.unix.questions] Core files ...

warner@scubed.UUCP (Ken Warner) (06/09/88)

Is there a way to run a core file?  I'm writing yet an other shell (yaos) and
I want to be able to save an image of it at some particular time and then 
at some later time restart it.  I think I can figure out how to dump a 
core file but how does one re-start it?  

I know most Lisp implementations allow you to save an image.  Would anyone
know have any insight into how that is done?  I'm on a Sun under OS 3.5
TIA!
Ken Warner

chris@mimsy.UUCP (Chris Torek) (06/14/88)

In article <790@scubed.UUCP> warner@scubed.UUCP (Ken Warner) writes:
>Is there a way to run a core file?

It cannot be done portably, but with certain restrictions, it can
almost always be done.

>I know most Lisp implementations allow you to save an image.  Would anyone
>know have any insight into how that is done?  I'm on a Sun under OS 3.5

Franz does it unportably: it writes its text image, then its data.  It
puts an appropriate executable header on the front, and adds a symbol
table.  When it starts up it checks to see if it was doing something
special before.

Note that file descriptors are generally lost, and that saving the
environment is sometimes wrong.  Generally, the best way to save state
is to save the important stuff instead of blindly writing everything.
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163)
Domain:	chris@mimsy.umd.edu	Path:	uunet!mimsy!chris