

Systems Programming in Distributed, Multicore World with Go, Rust, and Parasail - xkarga00
https://docs.google.com/viewer?a=v&pid=forums&srcid=MTM1Nzg0MDEwNzUyNTU3MjA2MDkBMTA5MjQ4NzMyOTM0MzU0MTc0OTEBRmM0Unk2OHZlODhKATAuMQEBdjI

======
kibwen
This article pops up every so often, so again I should emphasize that the
concurrency story in Rust has changed greatly in the interim (and will
continue to change as new approaches to concurrency are fleshed out in the
stdlib).

~~~
xkarga00
Can someone experienced in both Rust and Go comment on how the two languages
compare regarding concurrency? Is it more flexible having it in stdlib vs
being baked into the language? I regard myself as fairly experienced in Go and
find its concurrent primitives really straightforward to use. The whole
goroutines-channels-select package feels like a very powerful and easy to use
tool for concurrent code (though you can still shoot yourself in the foot).

~~~
bjz_
It is a great deal more flexible having concurrency constructs built as
library features as opposed to baked into the language. If the constructs
provided don't make the same performance tradeoffs that your use case demands,
you can build your own. These can provide safe, statically verified APIs by
leveraging Rust's ownership and lifetime semantics.

Unfortunately channel selection and futures are still pretty raw at the moment
(it remains to be seen if it will be ready for 1.0), but other constructs such
as threads, channels and mutexes are looking pretty strong for 1.0.

------
cpeterso
Here is a video of a talk the author, Tucker Taft, gave about the ParaSail
language at Mozilla last year:

[https://air.mozilla.org/region-based-storage-management-
para...](https://air.mozilla.org/region-based-storage-management-parasailing-
without-a-garbage-chute/)

------
nnutter
Seems like this is a better source of the article: [http://parasail-
programming-language.blogspot.com/2013/04/sy...](http://parasail-programming-
language.blogspot.com/2013/04/systems-programming-with-go-rust-and.html)

------
Animats
Unfortunately, it's a "why X is great, by the vendors of X" article. It's an
ad for ParaSail, which is too new (and possibly too weird) to have much
traction yet.

------
Dewie
Note that the document seems to be from the spring of last year.

I think it is interesting that Parasail has no explicit pointers and only uses
value semantics. This means that no garbage collection is needed: the storage
associated with a variable is freed when the variable goes out of scope, or
when the variables value is set to _null_ (and yes, you must have a value of
type Optional T in order to set it to null). I thought that having pure value-
semantics would be too costly in a language, but apparently that kind of
solution has its place after all.

~~~
q2
can you clarify how value semantics are costly compared to garbage
collection/explicit pointers?

~~~
Dewie
As far as I understand, and if no extra care is taken on the part of the
programmer: the extra copying, since you would have to copy over the data from
one variable to another instead of just using and moving around pointers. In
Parasail's case, you can choose to use "move" (move value from left side to
over to the right side) and "swap" (swap the values of the left and right
side), which will avoid the copying.

