3 ms·
Thank you very much for your time and your feedback which I really appreciate. > but they tend to perform poorly in manycore settings and are still vulnerable
by Rochus 3y ago
Thank you very much for your time and your feedback which I really appreciate.
> but they tend to perform poorly in manycore settings and are still vulnerable to deadlock [..] fundamentally, blocking synchronization of any kind is incompatible with modularity
Do you have references for this? With the selected version of signals (only an await procedure, no explicit signal required), the only way for a deadlock from my point of view is when a protected procedure calls directly or indirectly another protected procedure of the same monitor, thus trying to acquire the same lock twice. But this can be detected by the compiler. Or did I miss something?
> you're talking about the one in agha's 01985 dissertation
My reference is this book: https://direct.mit.edu/books/monograph/4794/ActorsA-Model-of-Concurrent-Computation-in https://direct.mit.edu/books/monograph/4794/ActorsA-Model-of.... It's essentially his PhD released as an MIT press book (at least I didn't see significant differences). But I prefer to reference books over PhDs if possible.
> objects with their own threads [..] are not the same thing as monitors
I'm not aware I claimed this. Will check whether the formulation is misleading. Actually I wanted to point out that the "objects with threads" in Active Oberon give little added value and are not "active objects" at all.
> you didn't mention javascript at all
Well, the intention was not to have a general discussion about concurrency in all programming languages; I'm primarily interested in the relatives of Oberon, plus a selection of languages based on CSP. I just mentioned Erlang because it is a prominent example of an Actor language. But I will have a look at more recent JS developments for ideas compatible with Oberon.
> javascript's concurrency model was originally that of original oberon
Just because of the message delegation/handler concept (which existed before Oberon)? I wasn't aware that there is a direct connection of JS and Oberon (it is not even mentioned in the 2020 JS HOPL paper).
> are the languages with the most promising approaches to the concurrency problem
Do you think that JS concurrency is better than Go concurrency, i.e. channels aren't worthwhile at all? Why?
> it might be worthwhile to at least mention the π-calculus
From my perspective, that's sufficiently covered by [13], as far as the concepts might be useful for Oberon+. Which relevant idea do you think is specifically missing?
> your reference [31] doesn't purport to show that no single concurrency construct is adequate
The paper explicitly states "Unfortunately, as it stands, there are simply a surprising amount of problems that are solved better with traditional synchronization primitives than with Go’s version of CSP. [..] The summary here is that you will be using traditional synchronization primitives in addition to channels if you want to do anything real", from which I conclude that channels alone are not good enough; this conclusion is also supported by [32], where one of the tables demonstrates that the analyzed projects use low-level primitives twice as much as channels. I agree with the author that there are problems which can more elegantly be solved with classic synchronisation (including monitors), regardless of possible design issues of Go; we could use channels to emulate those (as demonstrated), but for efficiency reasons I preferred to directly add monitors (as Go did with adding low-level primitives instead). I think monitors are still better than the Go sync package, and if everything else fails Oberon+ could access pthreads by FFI. But that's actually the main point where more thinking and discussions are required.