[Haskell-cafe] sharing
Tom Ellis
tom-lists-haskell-cafe-2017 at jaguarpaw.co.uk
Wed Feb 5 22:35:21 UTC 2020
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
Tom
More information about the Haskell-Cafe
mailing list