I am trying to parallelize my Femlisp application at some important points.
Especially, I would like to split the work at some points in the program
such that more processors are involved. I have the following questions:
1. Usually, the work to be done depends on information in the lexical
environment. But as much as I see threads generally communicate only
via special variables, which somehow does not fit very well this task.
What was the reason of this choice? Performance? Is there some way how
to achieve such a splitting and recombination of threads in a reasonably
nice way using the existing mechanisms?
2. Somewhat connected: Allegro's processes can be made to inherit some of
the active dynamic bindings (keyword initial-bindings). Is there a
possibility to achieve this in SBCL?
3. Is there an idiom for waiting until a thread / several threads has/have
terminated? I guess that (loop while (thread-alive-p thread)) is not very