[Haskell-cafe] Freeze/thaw fusion

Jake McArthur jake.mcarthur at gmail.com
Mon Aug 3 12:27:41 UTC 2015


Vector also does something like what your are describing. I think the
phrase to google for is "array recycling".

On 11:56PM, Fri, Jul 31, 2015 William Yager <will.yager at gmail.com> wrote:

> Has anyone done any research into fusing operations that involve thawing
> some data, mutating it, and then freezing it again?
>
> Data.Vector does something similar; it turns vectors into streams,
> operates on the streams, and then turns them back into vectors. It can fuse
> these operations by removing intermediate  However, I've done a bit of
> preliminary work on a fusion system that works on operations of the form
>
>     runST $ do
>         x' <- thaw x
>         foo x'
>         freeze x'
>
> and yields promising results in some cases. This could be useful for data
> structures that aren't stream-able, but suffer from lots of unnecessary
> freezing and unfreezing.
>
> This seems like the sort of thing that someone would have already done, so
> I wanted to check if anyone knew of any previous work on this.
>
> Cheers,
> Will
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20150803/b2f20558/attachment.html>


More information about the Haskell-Cafe mailing list