Re: Any way to track memory allocations?

2009-02-24 Thread wade
Thanks again for all the help. I found what the problem was and it wasn't obvious (at least to me): float[uint] arr; foreach (uint k; arr.keys) { ... } Changing this to: foreach (uint k, float v; arr) { ... } fixes the leak. I guess the keys array is constructed on the fly? wade L

Re: Any way to track memory allocations?

2009-02-24 Thread wade
Yes, this would be a great idea, especially for RT production software. wade Denis Koroskin Wrote: > On Tue, 24 Feb 2009 20:40:13 +0300, BCS wrote: > > > Reply to Jarrett, > > > > > >> Hm, actually.. > >> If you *are* using D2, you might be able to r

Re: Any way to track memory allocations?

2009-02-24 Thread wade
Thanks, That's helpful. I'm using D 1.0. I've eliminated all array concats, dups, etc. but there's still a significant amount of memory being allocated that I can't seem to detect. Perhaps, I can recompile an instrumented version of phobos... wade Jarrett Billings

Any way to track memory allocations?

2009-02-24 Thread wade Shen
Any recommendations would be appreciated. thanks, wade

nth_element implementation

2009-02-12 Thread Wade
Hi all, Does anybody have an efficient nth_element implementation (ala the STL) for D 1.0. I was using the version from algortihms.d in DMD 2.012 but that seems to be non-existent anymore and was quite buggy. thanks, wade