Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-14 Thread Peter Verswyvelen
it was on MS.NET 3.5 now the problem was the following the problematic object encapsulated a running timer. on each tick of the timer, I added an occurrence to a stream this stream was used in another thread, but the stream itself had no backpointer to the object that generated it so the object

Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-14 Thread Felipe Lessa
On Sat, Feb 14, 2009 at 3:18 PM, Peter Verswyvelen bugf...@gmail.com wrote: Do you think this is something to report as a bug to Microsoft? But this is a bit off topic in Haskell Cafe :-) I don't know how MS treats bug reports, but if you can make a small test case, then you should. It would

[Haskell-cafe] Re: space leak with 'concat' ?

2009-02-12 Thread Simon Marlow
Peter Verswyvelen wrote: Yes, I was really surprised that this was the case. I while ago I did a little FRP experiment. I made a top level binding to a list of timer event occurrences. The list was generated on another thread. To my surprise, I did not have space leak, which is amazingly cool,

Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-12 Thread Svein Ove Aas
On Thu, Feb 12, 2009 at 10:36 AM, Simon Marlow marlo...@gmail.com wrote: Peter Verswyvelen wrote: Yes, I was really surprised that this was the case. I while ago I did a little FRP experiment. I made a top level binding to a list of timer event occurrences. The list was generated on another

Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-12 Thread Peter Verswyvelen
On Thu, Feb 12, 2009 at 10:48 AM, Svein Ove Aas svein@aas.no wrote: Using this as a guide, I tested these two programs: str = concat $ repeat foo main1 = print foo main2 = print foo print foo = As I'm sure you realize, the first ran in constant memory; the second, not so

Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-12 Thread Felipe Lessa
2009/2/12 Peter Verswyvelen bugf...@gmail.com: It is funny that recently I had a strange problem in C# (I tried to write parts of Reactive in C#) where the garbage collector freed data that was actually needed by my program! I had to fix that by putting a local variable on the stack, passing

[Haskell-cafe] Re: space leak with 'concat' ?

2009-02-11 Thread Simon Marlow
Jake McArthur wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Henning Thielemann wrote: | in that module I defined the text to be printed as top-level | variable which might have been the problem. But this can't be the | problem of the compiled version of the program, where I encountered

Re: [Haskell-cafe] Re: space leak with 'concat' ?

2009-02-11 Thread Peter Verswyvelen
Yes, I was really surprised that this was the case. I while ago I did a little FRP experiment. I made a top level binding to a list of timer event occurrences. The list was generated on another thread. To my surprise, I did not have space leak, which is amazingly cool, but it felt odd :) Is it

[Haskell-cafe] Re: space leak with 'concat' ?

2009-02-11 Thread Jake McArthur
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Simon Marlow wrote: | FUD! CAFs are definitely garbage collected, in fact we have a big lump | of code generator and runtime complexity (Static Reference Tables, SRTs) | to ensure that they do. | | However, GHCi doesn't always GC CAFs, perhaps