[Haskell-cafe] Re: does the compiler optimize repeated calls?

David House dmhouse at gmail.com
Wed Sep 6 12:23:28 EDT 2006

On 06/09/06, David Roundy <droundy at darcs.net> wrote:
> Before something like this were to be implemented, I'd rather see
> automatic strictifying for avoidence of stack overflows (i.e. when the
> stack starts filling up, start evaluating things strictly), which is
> most likely another insanely dificult bit of compiler code, which
> would also involve figuring out which code paths would save memory,
> and which would increase the memory use.

Keep in mind that strict and lazy semantics aren't interchangeable,
that is automatic strictifying could change program behaviour unless
the compiler knew which bits need to be lazy. If it knew that, we
might as well adopt the 'strict where possible, lazy when necessary'

-David House, dmhouse at gmail.com

More information about the Haskell-Cafe mailing list