You don’t know till you measure!


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">If you are serious about getting the
best performance possible out of a managed app, you need to be using a
profiler.  The devs that designed
and wrote the "urn:schemas-microsoft-com:office:smarttags" /> style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">CLR style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"> still need to use a profiler to
judge how to improve the performance of a managed app.. o ns = "urn:schemas-microsoft-com:office:office" />


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"> 


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">Answer questions like how many
ArrayLists am I creating?  When is
my peak memory usage? 
Etc


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"> 


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">Here is one profiler… there are
others.  I know the guy that wrote
this one and is the same guy that made the GC scale super well on multi-proc
machines.  He knows memory
management inside and out…


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"> 


style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"> 


style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"> href="http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=36a3e666-6877-4c26-b62d-bfd7cb3154ac">http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=36a3e666-6877-4c26-b62d-bfd7cb3154ac style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-ansi-language: SV"> 


style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-ansi-language: SV">Happy
Profiling!


 

Comments (3)

  1. Ken Cowan says:

    Your comments about memory profiling apply equally well to performance profiling. Also worth noting that you need to do this regularly. It’s very easy for a simple change to wreck your runtime or memory perf.

    Disclosure: I’m an architect for Compuware. We do profilers, but don’t read this as a pitch for our tools.

    KC

  2. That tool is wonderful, I absolutely love it.

    In my software I have found two pieces that were problematic on my average coding patterns: I use too many ArrayLists and allocate too many strings, and this tool was able to point that immediately.

    In the case of ArrayLists, I have found that you can save some memory if you allocate them for a specific size, rather than the default of 10 or 16. If you know that the list needs to grow, but is unlikely to, you should try to provide that information.

    Also, in a few places (this is gross), I use an object to store the information. So if I need to store a single value, I store it directly into the object. If more than one value is required, I remove the object, and place it inside an ArrayList, and put the arraylist into my object reference.

    Miguel

  3. 小说 says:

    The tool that you said is wonderful, I absolutely love it