Struggling to implement parallel foreach...

Timon Gehr timon.gehr at gmx.ch
Tue Jun 18 00:17:06 UTC 2019


On 18.06.19 01:15, Manu wrote:
> On Tue, Jun 18, 2019 at 8:35 AM Timon Gehr via Digitalmars-d
> <digitalmars-d at puremagic.com> wrote:
>>
>> On 17.06.19 22:11, Manu wrote:
>>>
>>> Everything I need to make a strong case revolves around shared; and
>>> since nobody on this forum seems to know what to do with shared (we've
>>> been arguing about it and doing exactly nothing for the 10 years I've
>>> been watching),
>>
>> Lack of activity doesn't imply lack of knowledge, it can just be lack of
>> management.
>>
>> There is too little activity for most issues with the language that require:
>> a) breaking a ton of code
>> b) adding a new data qualifier
>>
>> It is worse if a) and b) are combined with a high specification and
>> implementation effort and nobody who can spend enough time on the
>> compiler has an in-depth understanding of what needs to be done in every
>> corner of the language.
>>
>> I know multiple options for what to do, but they involve either a) or
>> b). So do your suggestions. This is why there hasn't been enough
>> activity, it is not a lack of theoretical understanding from every
>> single forum poster.
> 
> It took a mammoth effort to arrive at agreement that shared can't
> read/write. That's uncontroversial, trivial to implement, and won't
> break anything that's not already critically broken.
> Can we start there?
> ...

See my last post. I don't think we are there yet. Walter is actually 
leaning towards allowing default access on `shared` variables with 
sequential consistency guarantees.
I don't think he is on board with the redefinition of `shared` to 
`threadsafe`. For `threadsafe`, default access on unshared data must 
obviously be disallowed. For `shared` this is less obvious if you don't 
already assume it has the new meaning.

>>> I think I'm uniquely positioned to move the bar
>>> forward here and make something that's actually useful, and
>>> demonstrated what shared is actually for.
>>
>> I think you have useful perspectives on the application side and the
>> prioritization of issues to help adoption in your industry, but this
>> does not always translate to useful insights on language design. Our
>> conversations should involve more of you talking about important
>> applications and me talking about language design.
>>
>> Of course, this is all useless unless someone writes DIPs and someone
>> implements them.
> 
> Just write a patch. I will use a forked language and prove that it
> works or not. I would gladly never post in this forum again in my
> life; I hate this process more more than I can describe.
> 

Unfortunately I have another paper deadline in a few weeks, but maybe I 
can set aside a few weekends this summer to try to fix function qualifiers.


More information about the Digitalmars-d mailing list