Re: Hunting down rogue memory allocations?

2014-10-03 Thread Jacob Carlborg via Digitalmars-d-learn
On 02/10/14 22:31, Kiith-Sa wrote: If *time* spent by allocations is a problem, profile with `perf top` (assuming you have Linux): Look for 'gc', 'malloc', 'calloc', etc. (Plain perf record will also work, but not be as quick/interactive. CodeXL works too.) If you have OS X, you can use

Re: Hunting down rogue memory allocations?

2014-10-03 Thread thedeemon via Digitalmars-d-learn
On Thursday, 2 October 2014 at 20:16:56 UTC, Gary Willoughby wrote: Say i have created a program written in D, what tools are available for me to track memory allocations? I wrote a tiny module trackallocs.d that inserts a GC proxy and outputs to log file (or stdout) all the allocations,

Re: Hunting down rogue memory allocations?

2014-10-03 Thread Kiith-Sa via Digitalmars-d-learn
On Friday, 3 October 2014 at 08:18:45 UTC, thedeemon wrote: On Thursday, 2 October 2014 at 20:16:56 UTC, Gary Willoughby wrote: Say i have created a program written in D, what tools are available for me to track memory allocations? I wrote a tiny module trackallocs.d that inserts a GC proxy

Re: Hunting down rogue memory allocations?

2014-10-03 Thread thedeemon via Digitalmars-d-learn
On Friday, 3 October 2014 at 09:27:50 UTC, Kiith-Sa wrote: https://bitbucket.org/infognition/dstuff/src/ Mind if I use some parts of it in my profiler? (there's no license) Sure, it's in public domain (as noted in readme).

Hunting down rogue memory allocations?

2014-10-02 Thread Gary Willoughby via Digitalmars-d-learn
Say i have created a program written in D, what tools are available for me to track memory allocations? If you write a program and its performance is slow because you suspect too many allocations are taking place in unrecognised areas, what tools or techniques do you use to find where they

Re: Hunting down rogue memory allocations?

2014-10-02 Thread Kiith-Sa via Digitalmars-d-learn
On Thursday, 2 October 2014 at 20:16:56 UTC, Gary Willoughby wrote: Say i have created a program written in D, what tools are available for me to track memory allocations? If you write a program and its performance is slow because you suspect too many allocations are taking place in

Re: Hunting down rogue memory allocations?

2014-10-02 Thread Gary Willoughby via Digitalmars-d-learn
On Thursday, 2 October 2014 at 20:31:29 UTC, Kiith-Sa wrote: On Thursday, 2 October 2014 at 20:16:56 UTC, Gary Willoughby wrote: Say i have created a program written in D, what tools are available for me to track memory allocations? If you write a program and its performance is slow because