DConf '22 Talk: Structured Concurrency
Andrej Mitrovic
andrej.mitrovich at gmail.com
Thu Oct 13 12:17:03 UTC 2022
On Thursday, 13 October 2022 at 08:04:46 UTC, Sebastiaan Koppe
wrote:
> The sender/receiver model is literally just the abstraction of
> an asynchronous computation. This allows you to use it as a
> building block to manage work across multiple compute resources.
Really cool presentation!
Btw I've noticed some outdated comments:
https://github.com/symmetryinvestments/concurrency/blob/7e870ffecb651a3859fac0c05296a0656d9ee9bf/source/concurrency/utils.d#L58
https://github.com/symmetryinvestments/concurrency/blob/c648b1af23efb7930077451a372a15d72d78f056/source/concurrency/stoptoken.d#L132
pause() is in fact supported now in DMD. Druntime uses it for its
backoff spinlock implemented here:
https://github.com/dlang/dmd/blob/09d04945bdbc0cba36f7bb1e19d5bd009d4b0ff2/druntime/src/core/internal/spinlock.d
It was fixed in: https://issues.dlang.org/show_bug.cgi?id=14120
Someone should probably remove this outdated code and replace it
with 'pause' (the net effect is the same, it's just rep; nop;)
https://github.com/dlang/dmd/blob/09d04945bdbc0cba36f7bb1e19d5bd009d4b0ff2/druntime/src/core/internal/atomic.d#L668-L669
More information about the Digitalmars-d
mailing list