Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Embedded Perl - Saving State?

by otto (Beadle)
on Apr 30, 2009 at 18:48 UTC ( [id://761138]=note: print w/replies, xml ) Need Help??


in reply to Embedded Perl - Saving State?

My question is this: is it possible, in my C app, to save off the state of the interpreter and restore it later?

Sure you can, just as you can write a relational database in assembly.

Realistically you need to ask bigger questions of why? Why not just put it in hibernate? Why not save off the whole OS run-state which I believe you can do with hypervisors like vmware. You need to be able to ask the bigger question of why you want to do this.

It may be as easy as using Storable as one point, depending upon how the c/perl is stitched together.

Are there just a few global type objects, singletons, from which all other data within your perl code hang?

My suggestion is to draw pictures, I like pictures, and show what is in the perl code, what is in the code, how they communicate, what triggers communication, etc.

You can not well address this issue without a clear understanding of the architecture - yes you may have written it, but take a 50,000 ft view, not the 10 ft view, along with why, what is the driving issues, and the answer will probably pop right out.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://761138]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2024-04-25 10:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found