On Thu, Apr 14, 2022 at 2:41 PM Henry Rich <[email protected]> wrote:
> BUT I am sure that more is needed.  If task A wants to send info
> repeatedly to task B, say in a global name, there has to be a watertight
> way for B to know when the data is ready and for A to know when it is
> safe to overwrite it.  That's what I was talking about.

I guess a question here is: can we build a mutex out of a pyx?

And, that's difficult, because a pyx is anonymous, so from a threading
point of view it's "single use".

Maybe we can work out something where the pyx would also contain a
"next pyx" as well as a version number, and a single use gerund (along
the lines of a javascript promise) and/or some additional information
about stable parts of the symbol table, with a master thread mediating
in control of the "unstable parts". But I am not sure we should try to
go there.

Instead, I think we should break the problem into two pieces -- the
general case (where we let the user "roll their own") and the typical
case (where we want to let independent code run to completion and then
rendezvous. And, frankly, the "pyx" implementation goes a long way
towards satisfying the typical case needs.

Anyways, I think we have time to think about this.

Thanks again,

-- 
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to