[CM] Question about migrating values between interpreters

bil at ccrma.Stanford.EDU bil at ccrma.Stanford.EDU
Thu Feb 26 14:44:17 PST 2026


If you call s7_init to populate the pool of interpreters,
you can maintain a parallel array of the resulting
s7_scheme pointers, and get at the local values via
s7_symbol_value or s7_name_to_value. My initial idea
was that for variables global to the interpreters,
you'd want to use a data base library to make sure reads
and writes are handled cleanly.  I envisaged the values
in the data base as strings that could be read and
written as needed into scheme via s7_object_to_c_string
and s7_eval_c_string.  I think it might be unsafe to
use the s7 value itself because it is actually local
to some interpreter which you might free.  Perhaps
have an interpreter that handles all the pool's globals
and is guaranteed to be around until the program quits.
I haven't tried much in this area, so there are probably
better ways of handling this.



More information about the Cmdist mailing list