Cost of Overloading vs. HOFs

Conal Elliott conal at conal.net
Fri May 4 20:06:10 EDT 2007


Cool.  You know which types to consider because jhc is a whole-program
compiler?

Given the whole program, why not monomorphize, and inline away all of the
dictionaries?

 - Conal

On 5/4/07, John Meacham <john at repetae.net> wrote:
>
> On Fri, May 04, 2007 at 03:07:41PM -0700, Conal Elliott wrote:
> > Does anyone know what became of Dictionary-free Overloading by Partial
> > Evaluation <http://web.cecs.pdx.edu/%7Empj/pubs/pepm94.html>?  Is it
> > impractical for some reason?
>
> jhc also uses a dictionary free approach, doing a case directly on the
> type parameter.
>
> The nice thing about this is that _all_ methods can be determined by a
> single case evaluation, because finding out the right instance for any
> method will determine the right instance for all other methods too for a
> given type. The standard case-of-known-value optimization takes care of
> later scrutinizations (method lookups) on the same type.
>
>         John
>
>
> --
> John Meacham - ⑆repetae.net⑆john⑈
> _______________________________________________
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users at haskell.org
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/glasgow-haskell-users/attachments/20070504/f9abb7a4/attachment-0001.htm


More information about the Glasgow-haskell-users mailing list