[Haskell-cafe] Lessons from memory leak in streaming parser

2007-04-21 Thread Oren Ben-Kiki
of the YamlReference package I just uploaded to the Cabal database. This is intended to be an executable version of the YAML specification (the BNF file, which is actually Haskell code, is almost exactly the list of spec BNF productions). Thanks again for all the help, Oren Ben-Kiki

[Haskell-cafe] Profiling makes memory leak go away? Is Haskell a practical language?

2007-04-10 Thread Oren Ben-Kiki
On Tue, 2007-04-10 at 12:14 +0200, apfelmus wrote: Oren Ben-Kiki wrote: The code is in http://hpaste.org/1314#a1 if anyone at all is willing to take pity on me and explain what I'm doing wrong. There is an important point to note about streaming, namely that it conflicts with knowing whether

[Haskell-cafe] Profiling makes memory leak go away? Is Haskell a practical language?

2007-04-09 Thread Oren Ben-Kiki
Chasing down my memory leak I got into a weird situation where adding a magic manual SCC section and compiling with -prof makes the leak disappear. Now, I'll take any solution I can find - but this black voodoo only works for the short program I created for investigating the leak. It fails on the

[Haskell-cafe] Stubborn memory leak

2007-04-08 Thread Oren Ben-Kiki
I've minimized my problem to a short test program I pasted at http://hpaste.org/1314 The problem seems to be in forcing strict evaluation at just the right place, but all my attempts in doing so have causes the program to stop streaming and start consuming memory again - this time in un-emitted

[Haskell-cafe] Memory leak in streaming parser

2007-04-03 Thread Oren Ben-Kiki
that. Trying to `seq` things again either kills streaming or has no effect. Perhaps my basic approach is wrong... Any advice would be appreciated, Oren Ben-Kiki ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo

Re: [Haskell-cafe] Memory leak in streaming parser

2007-04-02 Thread Oren Ben-Kiki
to tokens) or had no effect (memory blows up due to states). I am assuming that there's a magic point in the middle where tokens are consumed and states are GC-ed... but it has eluded me so far. Thanks, Oren Ben-Kiki P.S. I uploaded the package to Hackage. I added a debug-leak production

[Haskell-cafe] Memory leak in streaming parser

2007-04-01 Thread Oren Ben-Kiki
to stdout and an ever-climbing memory usage in top (or htop). Any advice would be appreciated, Oren Ben-Kiki ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe