[Haskell-cafe] sharing

Tom Schouten tom at zwizwa.be
Thu Feb 6 01:09:22 UTC 2020


On 2/5/20 5:35 PM, Tom Ellis wrote:
> On Wed, Feb 05, 2020 at 07:56:39AM -0500, Tom Schouten wrote:
>> Is there currently a consensus on what is the best way to embed a pure
>> dataflow language while keeping control over value sharing?
> Have you looked into how Edward Kmett's AD package does observable
> sharing?  Observable sharing is particularly important for reverse
> mode AD.
>
> -- For this form of reverse-mode AD we use 'System.Mem.StableName.StableName' to recover
> -- sharing information from the tape to avoid combinatorial explosion, and thus
> -- run asymptotically faster than it could without such sharing information, but the use
> -- of side-effects contained herein is benign.
>
> https://github.com/ekmett/ad/blob/c3d9599030f7e4793896013c69ab6b19ce403906/src/Numeric/AD/Internal/Kahn.hs

No, and thanks!

Getting many great responses. Will have to chew on this for a bit.





More information about the Haskell-Cafe mailing list