Login to participate
  
Register   Lost ID/password?
Louis Kessler’s Behold Blog » Blog Entry           prev Prev   Next next

Profilers and Memory Debuggers - Mon, 13 Oct 2008

I used two tools with Delphi 4 to help optimize Behold and check for memory leaks.

GpProfile by Primoz Gabrijelcic (hence the Gp) was a free profiler for Delphi 2, 3, 4 and 5. I used it quite a bit for optimizing Behold and especially the guts of TRichView. Many of the improvements I found for TRichView I gave to Sergey and were included in later versions of it.

By the end of 2000, GpProfile was no longer supported. It worked for me up to now, since I was still using Delphi 4. But I don’t trust it to work with Delphi 2009. So I need something else.

The tool I used to optimize memory and look for leaks was Memory Sleuth by TurboPower. When I got it 10 years ago, it was free. They later came out with Version 2 and Version 3 and by then were charging $349 US for it. I never upgraded, since what it did in the early free version worked well enough for me. But that whole company closed in 2003 and they made most of their programs OpenSource. I don’t think MemorySleuth was one of them and it is now a relic as well.

So I will need something new that works with Delphi 2009. For profilers, I can only seem to find two. One is ProDelphi. It doesn’t look bad and I’d need the professional version which costs 57.5 Euros (or about $80 US). The other is AQtime by AutomatedQA, and I’ll talk about that in a moment.

For memory debuggers, there’s one that stands out. It’s MemProof by Atanas Soyanov and it’s free. Just one problem. It was bought out by AutomatedQA. They made it available free for awhile, but last year they took MemProof off their website and integrated all its functionality into AQtime.

The good thing about AQtime is that it is apparently a fantastic product. It has won Delphi best software awards for several years and the integration with Delphi and capabilities seem amazing. The bad thing is that it will cost me $599 US and the Canadian dollar has just dipped 15% in the last month (ouch). That’s almost as much as the full version of Delphi 2009 costs.

But looking at AQtime, and looking at my plans and my optimization needs for Behold, I expect I will go for the 30 day download trial once I begin that task, and after 30 days then decide whether to purchase it. I expect that I will.

I am looking forward to seeing what amazing things it will do for Behold once I start optimizing the new core of TRichView, Virtual Treeview, and the implementation of the DISQLite3 database package.

3 Comments           comments Leave a Comment

1. uwe (uwe)
United States flag
Joined: Tue, 14 Oct 2008
20 blog comments, 0 forum posts
Posted: Tue, 14 Oct 2008  Permalink

Hi Louis

The best option you have is FastMM in full debug mode.

Regarding the speed of D2009: it should be much faster than 16 secs to start it up. How much RAM do you have?

VirtualShellTools are very powerful (I use them myself), but they have a steep learning curve and there’s almost no documentation available.

Just my 2c
Uwe

2. Louis Kessler (lkessler)
Canada flag
Joined: Sun, 9 Mar 2003
287 blog comments, 245 forum posts
Posted: Tue, 14 Oct 2008  Permalink

Delphi’s default memory manager was changed to FastMM4 a few years ago, so I’m looking forward to the improvements that alone will provide. From what I recall in reading about it some time ago, I don’t think the full debug mode is included in the version in Delphi, but there is some debugging and probably logs of memory leaks that can be saved. Even so, I believe AQtime can report so much more about the memory in a more usable and convenient manner. If I’m going to get serious about making Behold work well, then it would help having a top-notch tool to make that job easier.

I develop on a 3 MHz single core Intel chip computer, Windows XP, with 3 GB RAM. That should be plenty. There are a bunch of package names that fly by as Delphi 2009 is loading. I’ll have to look more closely at what they are tonight. Adobe Photoshop Elements takes about 30 seconds to start up. Maybe it’s my AVG antivirus or my Diskeeper defragmenter or my X1 file indexer that’s slowing these down.

Virtual Shell Tools and the accompanying website’s products look very interesting and use Virtual Treeview as its basis. But Behold doesn’t do enough Shell and directory management to make that a necessity. They’ve got some great components, though.

Louis

3. uwe (uwe)
United States flag
Joined: Tue, 14 Oct 2008
20 blog comments, 0 forum posts
Posted: Tue, 14 Oct 2008  Permalink

Even though FastMM is part of Delphi now, you can still incorporate the latest version from Sourceforge in your project and use the full debug capabilities. You won’t find a better tool for tracing memory leaks, IMHO.

AntiVirus software is usually the culprit when experiencing a slow Delphi start-up. I had the same problems with D2007 in the beginning.

Good luck
Uwe

Leave a Comment

You must login to comment.

Login to participate
  
Register   Lost ID/password?