On Thu, 2007-05-03 at 16:24 +0100, Adrian Hey wrote:
> Hello Folks,
> 
> Just wondering about this. Please understand I'm not asking why
> programs use a lot of stack sometimes, but specifically why is
> using a lot of stack (vs. using a lot of heap) generally regarded
> as "bad". Or at least it seems that way given that ghc run time
> makes distinction between the two and sets separate
> limits for them (default max stack size being relatively small
> whereas default max heap size in unlimited). So programs can
> fail with a stack overflow despite having bucket loads of heap
> available?

Perhaps it's there to help people who write simple non-terminating
recursion. They'll get an error message fairly soon rather than using
all memory on the machine and invoking the wrath of the OOM killer.

Duncan

_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to