Potential GSoC proposal: Reduce the speed gap between 'ghc -c' and 'ghc --make'
Mikhail Glushenkov
the.dead.shall.rise at gmail.com
Thu Apr 26 23:34:24 CEST 2012
Hello Simon,
On Wed, Apr 25, 2012 at 9:57 AM, Simon Marlow <marlowsd at gmail.com> wrote:
>
>>
>> Is this a good idea? How hard it would be to implement this optimisation?
>
> [...] Personally I think it's at
> best very ambitious, and at worst not at all practical.
Thanks. I'll look into how to optimise .hi loading by more traditional
means, then.
I briefly looked at how marshalling is implemented in Ocaml
(byterun/intern.c), and it looks like even though the Marshal module
is unsafe and saves the data in an opaque format, the deserialisation
algorithm is less radical than what I proposed. They go through the
input buffer looking at the tag and size of the each object, and copy
them to the heap buffer one-by-one. One interesting detail is that the
heap buffer is allocated only once, because its size is known in
advance.
--
() ascii ribbon campaign - against html e-mail
/\ www.asciiribbon.org - against proprietary attachments
More information about the Glasgow-haskell-users
mailing list