Wandering amongst the dragons here, seeking insight from the wizards.
Suppose I'm embedding Perl in my C app, as is so well documented in
perlembed. I've constructed a
PerlInterpreter my_perl, parsed my Perl code, and I'm occasionally calling
call_argv("MyPerlFunction", ...);.
My question is this: is it possible, in my C app, to save off the state of the interpreter and restore it later?
I'm thinking of something like serializing
my_perl, perhaps to disk, and restoring it later - thus saving not only the parsing/compiling, but more importantly, saving the state of things like Perl variables, etc.
I've read the docs and searched the net, but so far I'm coming to the conclusion that this may not be feasible with the API provided - I'd have to hack the perl library itself to provide a serialization interface, which might be a bridge too far.
What say ye, oh deep hackers?
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.