Delphi 分析工具 [英] Delphi Profiling tools

查看:38
本文介绍了Delphi 分析工具的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的 Delphi 2006 应用程序出现了一些性能问题.你能推荐任何可以帮助我找到瓶颈的分析工具吗

I am having some performance problems with my Delphi 2006 app. Can you Suggest any profiling tools that will help me find the bottle neck

即像turbo Profiler这样的工具

i.e. A tool like turbo Profiler

推荐答案

我问了同样的问题 问题不久前

I asked the same question not too long ago

我已经下载并试用了 AQtime.它看起来确实很全面,但它不是一个易于使用的工具,而且对于单个程序员来说非常昂贵(即 600 美元).我喜欢这样一个事实,即它是非侵入性的(没有更改您的代码),并且它可以进行逐行分析,直到我发现因为它是一个检测分析器,所以它可能会导致不正确的优化,如下所示:为什么 CharInSet 比 Case 语句快?

I've downloaded and tried AQtime. It does seem comprehensive, but it is not an easy to use tool and is VERY expensive for an individual programmer (i.e. $600 US). I loved the fact that it was non-invasive (did not change your code), and that it could do line-by-line profiling, until I found that because it is an instrumenting profiler, it can lead to improper optimizations as in: Why is CharInSet faster than Case statement?

我尝试了 ProDelphi 的演示,便宜得多(我认为大约 80 美元),但它对我来说太笨重了 - 我根本不喜欢用户界面,而且它是侵入性的 - 更改您的代码以添加仪表,你必须小心.

I tried a demo of ProDelp much less expensive (about $80 I think), but it was much too clunky for me - I didn't like the user interface at all, and it is invasive - changing your code to add the instrumenting, which you have to be careful about.

我在 Delphi 4 中使用 GpProfile 很多年了.我爱它.它也具有侵入性,但效果很好,我学会了信任它,而且 10 年来它从未给我带来任何问题.但是当我升级到 Delphi 2009 时,我认为最好不要尝试使用它,因为它没有升级,而且据 GP 承认,如果不进行修改将无法使用.我希望你也不能在 Delphi 2006 中使用它.

I used GpProfile with Delphi 4 for many years. I loved it. It also was invasive, but it worked so well I learned to trust it and it never gave me a problem in 10 years. But when I upgraded to Delphi 2009, I didn't think it best to try using it, since it hasn't been upgraded and by GP's admission, won't work without modifications. I expect you won't be able to use it either with Delphi 2006.

ProDelphi 和 GpProfile 将仅在过程级别进行分析.如果你想做单独的行(我有时不得不这样做),你必须为每一行调用 PROC1、PROC2、PROC3,并将一行放在每个 PROC 中.不得不这样做有点烦人,但它给了我很好的结果(至少我对 GpProfile 这样做的结果很满意).

ProDelphi and GpProfile will only profile at the procedure level. If you want to do individual lines (which I sometimes had to), you have to call PROC1, PROC2, PROC3 for each line and put the one line in each PROC. It was a bit of an annoyance to have to do that, but it gave me good results (at least I was happy with the results of GpProfile doing that).

我在 CharInSet 问题中接受的答案是采样分析器,它定期检查 CPU 的位置,通常更适合测量代码时间."和后来的 answer 提供了 Eric Grange 的 Delphi 免费采样分析器,现在支持 Delphi2009 年.我还没有尝试过,但我听说过它的好消息,下一个我要尝试.

The answer I accepted in my CharInSet question said that "Sampling profilers, which periodically check the location of the CPU, are usually better for measuring code time." and a later answer gave Eric Grange's free sampling profiler for Delphi that now supports Delphi 2009. I haven't tried it yet, but I've heard good things about it, and it is the next one I'm going to try.

顺便说一句,您最好不要购买 AQtime,从而节省 600 美元,而是用它来将您的 Delphi 2006 升级到 Delphi 2009.稳定性、速度和额外功能(尤其是 Unicode)将值得您使用尽管.请参阅:升级到 D2009 的主要激励措施是什么(不包括Unicode)?

By the way, you might be best off by saving your $600 by NOT buying AQtime, and instead using that to upgrade your Delphi 2006 to Delphi 2009. The stability, speed and extra features (expecially Unicode), will be worth your while. See: What are major incentives to upgrade to D2009 (Unicode excluded)?

此外,AQtime 还没有集成到 Delphi 2009 中.

Also AQtime does not integrate into Delphi 2009 yet.

另一个免费的,我发现了来源,但还没有尝试过是 TProfiler.如果有人尝试过那个,我想知道他们的想法.

One other free one, with source that I found out about, but haven't tried yet is TProfiler. If anyone has tried that one, I'd like to know what they think.

注意:我后来添加到 问题 291631 的附录似乎就像它可能是答案.参见 Andre 的开源程序:asmprofiler

Note: The Addenum I added afterwards to question 291631 seems like it may be the answer. See Andre's open source program: asmprofiler

2010 年 2 月跟进.我硬着头皮买了AQTime.几个月前,他们终于将它集成到我使用的 Delphi 2009 中(但他们仍然必须使用 Delphi 2010).查看源代码行及其单独的时间和计数对我来说是无价的,AQTime 在这方面做得非常出色.

Feb 2010 followup. I bit the bullet and purchased AQTime. A few months ago they finally integrated it into Delphi 2009 which is what I use (but they still have to do Delphi 2010). The viewing of source lines and their individual times and counts is invaluable to me, and AQTime does a superb job of this.

这篇关于Delphi 分析工具的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆