Sharing in D

Sean Kelly sean at invisibleduck.org
Fri Aug 1 11:51:42 PDT 2008


== Quote from superdan (super at dan.org)'s article
>
> in the shared cases we have:
> unshared == never seen by 2 threads
> ? == ?
> shared == fuck you, i'm shared
> so how would that go. i won't share it? i won't write to it? (that's useless bc of read fences.) anyway
this is intriguing shit. unification is power.

Yeah, the idea of having a unifying label makes some sense, but I haven't been
able to figure out what it would mean in terms of behavior.  Maybe the middle
one would be volatile in that the compiler doesn't optimize use of it but doesn't
go so far as to bother with fences?  But then the middle ground would be like
expert mode, which isn't really what you want.  Maybe we're good with just
shared and unshared.


Sean



More information about the Digitalmars-d mailing list