Re[2]: [Haskell-cafe] Questions about slow GC with STArray
Hello Dan, Monday, April 6, 2009, 12:35:14 PM, you wrote: the size of the sub-array. The test then fills a 10 million element array. However, something about the benchmark makes it perform poorly for both small chunks and large chunks. -sstderr reports that lots of copying occurs for small chunk sizes, and I haven't bothered to figure out why this is the case. You can, however, see that marking dirty chunks in this fashion would be profitable. The un-chunked array takes around a minute here, while with chunks of 10,000 (which seems to be about the optimal value with the above copying tradeoff), it takes about 6 seconds, and that's still with 60+% GC time. i don't think that 60% GC time is bad for *this* benchmark. array filling is very trivial operation, after all. important part is 10x GC times reduce, apply these numbers to original benchmark -- Best regards, Bulatmailto:bulat.zigans...@gmail.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re[2]: [Haskell-cafe] Questions about slow GC with STArray
Hello FFT, Monday, April 6, 2009, 12:32:53 PM, you wrote: you need to scan only boxes: if array just contains plain cpu-level numbers, there is nothing to scan Are those the only legal contents of STUArray? numbers, chars, vanilla pointers. UArray just mimics C arrays, after all -- Best regards, Bulatmailto:bulat.zigans...@gmail.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: Re[2]: [Haskell-cafe] Questions about slow GC with STArray
On Mon, Apr 6, 2009 at 1:49 AM, Bulat Ziganshin bulat.zigans...@gmail.com wrote: Are those the only legal contents of STUArray? numbers, chars, vanilla pointers. UArray just mimics C arrays, after all I haven't gotten to learning about them in detail yet, but my hope was that STUArray was like vectorT in C++, and STArray was like vectorT*. Both are fairly general. So if I need a array of complex numbers in Haskell, will I need an extra level of indirection compared to C? And in addition to that some serious issues with GC speed if those arrays need to be mutable? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe