Re: storing highly shared data structures

2006-01-12 Thread Christian Maeder
Bulat Ziganshin wrote: char *ghc_rts_opts = -A10m; (see 4.14.5 in GHC user manual) Yes, thanks, that is better for me Christian ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org

Re: storing highly shared data structures

2006-01-11 Thread Simon Marlow
Bulat Ziganshin wrote: Hello Simon, Tuesday, January 10, 2006, 12:26:30 PM, you wrote: CM My old version is faster, because the version with makeStableName does CM very much GC. CMMUT time 27.28s ( 28.91s elapsed) CMGCtime 133.98s (140.08s elapsed) try to add infamous

Re: storing highly shared data structures

2006-01-11 Thread Christian Maeder
Simon Marlow wrote: You can change the allocation area size from within a program quite easily. Write a little C function to assign to RtsFlags.GcFlags.minAllocAreaSize (#include RtsFlags.h first), and call it from Haskell; the next time GC runs it will allocate the larger nursery. Please

Re: storing highly shared data structures

2006-01-11 Thread Esa Ilari Vuokko
On 1/11/06, Christian Maeder [EMAIL PROTECTED] wrote: Simon Marlow wrote: You can change the allocation area size from within a program quite easily. Write a little C function to assign to RtsFlags.GcFlags.minAllocAreaSize (#include RtsFlags.h first), and call it from Haskell; the next

Re: storing highly shared data structures

2006-01-11 Thread Simon Marlow
Esa Ilari Vuokko wrote: On 1/11/06, Christian Maeder [EMAIL PROTECTED] wrote: Simon Marlow wrote: You can change the allocation area size from within a program quite easily. Write a little C function to assign to RtsFlags.GcFlags.minAllocAreaSize (#include RtsFlags.h first), and call it

Re: storing highly shared data structures

2006-01-10 Thread Simon Marlow
Christian Maeder wrote: Bulat Ziganshin wrote: CM My old version is faster, because the version with makeStableName does CM very much GC. CMMUT time 27.28s ( 28.91s elapsed) CMGCtime 133.98s (140.08s elapsed) try to add infamous +RTS -A10m switch ;) You saved my day,

Re: storing highly shared data structures

2006-01-10 Thread Jan-Willem Maessen
On Jan 10, 2006, at 4:26 AM, Simon Marlow wrote: Christian Maeder wrote: Bulat Ziganshin wrote: CM My old version is faster, because the version with makeStableName does CM very much GC. CMMUT time 27.28s ( 28.91s elapsed) CMGCtime 133.98s (140.08s elapsed) try to add

Re: storing highly shared data structures

2006-01-10 Thread Simon Marlow
Jan-Willem Maessen wrote: On Jan 10, 2006, at 4:26 AM, Simon Marlow wrote: Christian Maeder wrote: Bulat Ziganshin wrote: CM My old version is faster, because the version with makeStableName does CM very much GC. CMMUT time 27.28s ( 28.91s elapsed) CMGCtime 133.98s

Re: storing highly shared data structures

2006-01-09 Thread Simon Marlow
Christian Maeder wrote: Simon Marlow wrote: Right - Ptr isn't the right thing here, because GC will move objects around. That's why we have StablePtr and StableName. may it be that makeStableName is expensive? (or it is my additional Map?) My old version is faster, because the version

Re: storing highly shared data structures

2006-01-09 Thread Christian Maeder
Bulat Ziganshin wrote: CM My old version is faster, because the version with makeStableName does CM very much GC. CMMUT time 27.28s ( 28.91s elapsed) CMGCtime 133.98s (140.08s elapsed) try to add infamous +RTS -A10m switch ;) You saved my day, thank you Bulat! Without

Re: storing highly shared data structures

2006-01-09 Thread Christian Maeder
Bulat Ziganshin wrote: try to add infamous +RTS -A10m switch ;) Maybe -H300m is more famous? MUT time 24.92s ( 29.79s elapsed) GCtime6.32s ( 7.67s elapsed) EXIT time0.00s ( 0.00s elapsed) Total time 31.24s ( 37.46s elapsed) Christian

Re: storing highly shared data structures

2006-01-06 Thread Christian Maeder
Simon Marlow wrote: Right - Ptr isn't the right thing here, because GC will move objects around. That's why we have StablePtr and StableName. may it be that makeStableName is expensive? (or it is my additional Map?) My old version is faster, because the version with makeStableName does

Re: storing highly shared data structures

2006-01-02 Thread Benjamin Franksen
On Thursday 29 December 2005 18:22, Christian Maeder wrote: Einar Karttunen wrote: On 22.12 14:43, Christian Maeder wrote: How can I detect this sharing in order to avoid traversing the very same symbol table for every symbol? By using System.Mem.StableName SerTH

Re: storing highly shared data structures

2005-12-29 Thread Christian Maeder
Einar Karttunen wrote: On 22.12 14:43, Christian Maeder wrote: How can I detect this sharing in order to avoid traversing the very same symbol table for every symbol? By using System.Mem.StableName SerTH (http://cs.helsinki.fi/u/ekarttun/SerTH/) implements this, so you can look at the source

RE: storing highly shared data structures

2005-12-23 Thread Simon Marlow
On 22 December 2005 13:43, Christian Maeder wrote: for storing highly shared data structures we use so called Annotated Terms (shortly ATerms, details below). http://www.cwi.nl/htbin/sen1/twiki/bin/view/SEN1/ATerm In contrast to the Binary (or GhcBinary) class we compute the sharing,

Re: storing highly shared data structures

2005-12-22 Thread Einar Karttunen
On 22.12 14:43, Christian Maeder wrote: How can I detect this sharing in order to avoid traversing the very same symbol table for every symbol? By using System.Mem.StableName SerTH (http://cs.helsinki.fi/u/ekarttun/SerTH/) implements this, so you can look at the source for pointers. I've