Skip Cave wrote:
> For example the function "parallel" could be used to place the function
> in the right argument into a specific processor, and then continue
> execution with the next statement in the script. So the script:
> 
> parallel A
> parallel B
> parallel C
>
> Would result in the functions A, B, and C being run on separate threads,
> with each thread placed in a separate processor.
 
But what does that mean?
 
Let's say that we've got several arrays, and the functions A, B and C
correspond to the three blocks generated by:
   var=: ([EMAIL PROTECTED] { ])bind'abcdefghijklmnopqrstuvwxyz'"0 bind i.
   op=: ([EMAIL PROTECTED] { ])bind'+*%,-'"0 bind i.
   exp=: var,.'=',.':',.var,.op,.var
   exp"0(4 4 4)
 
What happens when the same variable is referenced in
multiple threads?  
 
Random results and errors?  Modify in place gets replaced
by a slower technique?
 
(Would it acceptable to make J substantially slower in contexts
where it's currently fast so that it can run multiple threads?)
 
-- 
Raul
 
 
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to