What about much coarser level threading? Was Re: Questions on Squeak's threading architecture

Ed Boyce edboyce at bu.edu
Wed Aug 4 20:19:01 UTC 2004


Tim Rowledge wrote:

>Ed Boyce <edboyce at bu.edu> wrote:
>
>  
>
>>     What is stopping Squeak from doing SMP?  (or Async MP for that matter?)
>>    
>>
>very little of the class tree is thread-safe. Consider one
>thread adding items to a collection whilst another removes them - you'd
>need interlocks/monitors/semaphores/whatever. We don't have them
>installed everywhere and likely never will. Unless of course someone
>really feels the urge to completely  rewrite a huge amount of code to
>support such fine threadiong safely. In practice you can get away with
>a huge amount, as always. Just don't sell the code to a nuclear
>powerplant operator, please!
>
>  
>
Thanks Tim.

     I have a follow-up question if I may: What about parallelizing 
things at a much coarser level?  Like within an SMP machine running a 
SMP capable OS, load N copies of the whole Squeak VM (or perhaps a pared 
down core of it), each into its own protected memory local to its very 
own processor on which it runs as a process that is tied to that 
processor, and then allow certain high-level userland objects to pass 
messages to cousin objects running on the VMs of other Squeak images on 
other processors through a piece of "globally" shared memory.  I say 
"let certain objects" do this, because those objects would have to be 
designed to play nice within their specially designed message sharing 
space, and the host OS probably needs some kind of NUMA support (which 
Linux does have).

     This technique would be most helpful for serving simulations that 
are "embarrassingly parallel" (or merely factorizable into 
non-interacting or weakly interacting parts) but which have to compare 
some manageable bandwidth of notes every once in a while on their 
relative states, positions, and whatever fields or forces they might be 
mutually generating or reacting to and report their states to a renderer 
(presumably running on its own Squeak instance with access to a fast 
video card).

     So, does the Squeak VM use any system-absolute global variables 
that would prevent one from running multiple instances of itself as 
separate processor-bound processes on a SMP supercomputer?

     Thanks again.

               -- Ed Boyce

---------------------------------------------------
Ed Boyce
Boston University Center for Computational Science
EOT-PACI Program -- http://www.eot.org
(413) 245-3997
edboyce at bu.edu





More information about the Squeak-dev mailing list