I'm not sure it's the type inference so much as the type abstractions and applications. But yes, your point is a good one
S | -----Original Message----- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On | Behalf Of Simon Marlow | Sent: 28 May 2003 18:03 | To: Simon Peyton-Jones; Ralf Hinze | Cc: GHC bugs | Subject: RE: GHC *is* resource hungry | | As far as I know, Hugs doesn't hash-cons types, yet it manages to | typecheck these pathalogical examples in reasonable time/space. I | vaguely recall there being a specific modification to Hugs's typechecker | to handle this, but I can't remember what it was. | | Cheers, | Simon | | > -----Original Message----- | > From: [EMAIL PROTECTED] | > [mailto:[EMAIL PROTECTED] On Behalf Of | > Simon Peyton-Jones | > Sent: 28 May 2003 15:57 | > To: Ralf Hinze | > Cc: GHC bugs | > Subject: RE: GHC *is* resource hungry | > | > I bet it's massive types. Translate the program into system | > F and see. | > (I remember this came up when looking at Okasaki's sequences of code | > combinators.) | > | > GHC doesn't try to hash-cons types, because it usually doesn't matter, | > but I bet it does here. | > | > S | > | > | -----Original Message----- | > | From: [EMAIL PROTECTED] | > [mailto:[EMAIL PROTECTED] On | > | Behalf Of Ralf Hinze | > | Sent: 28 May 2003 15:32 | > | To: [EMAIL PROTECTED] | > | Subject: GHC *is* resource hungry | > | | > | Here is a harmless little program (no recursion, no data types) | > | which GHC doesn't manage to compile (well, the kernel kills GHC | > | after a while on a machine with generous 512MB of main memory | > | and 1GB of swap space). | > | | > | > begin next = next id | > | > leaf k i next = next (k i) | > | > fork k next = next (\ t u -> k (t + u)) | > | > end x = x | > | > main = print (begin fork fork fork fork fork fork fork fork fork | > fork leaf 0 leaf 0 leaf 0 leaf 0 leaf 0 | > | leaf 0 leaf 0 leaf 0 leaf 0 leaf 0 leaf 0 end) | > | | > | Both Hugs and nhc98 accept it almost immediately. | > | | > | Cheers, Ralf | > | | > | _______________________________________________ | > | Glasgow-haskell-bugs mailing list | > | [EMAIL PROTECTED] | > | http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs | > | > | > _______________________________________________ | > Glasgow-haskell-bugs mailing list | > [EMAIL PROTECTED] | > http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs | > | > | _______________________________________________ | Glasgow-haskell-bugs mailing list | [EMAIL PROTECTED] | http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs _______________________________________________ Glasgow-haskell-bugs mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs