Browse by Tags

All Tags » Optimization (RSS)

Poor developer’s performance profiler

In the last post I wrote about a simple method that can help .NET developers micro measure the memory consumption of their application, in this post I want to show a way to measure application performance. Before I start I want to state here and now that there is no substitute to using an actual profiling application that will can find performance bottlenecks and problematic code, but if you have a small piece of code that needs profiling or you have a good idea where your problems lie then keep...
Posted by dhelper | with no comments

Poor developer’s memory profiler

Some tools save you money. The rule of the thumb is that if you save X days using the tool and your salary is Y dollars (or whatever you get paid with) per day then the tool is worth X times Y - it’s that simple. Over the years I’ve used several tools to do performance profiling but I’ve never quite found a good memory profiler. Although there are some solid and effective memory profilers for .NET - they tend to run forever and the results they supply are less than optimal, using a memory profiler...
Posted by dhelper | 4 comment(s)

Performance optimization tip – understand your memory layout

.NET take care of all memory allocation and de-allocation and after a while it seems that programmers no longer need to understand exactly how data is stored in the memory. The idea of not needing to know how data is stored could not be farther from the truth, in fact memory layout have great impact on code performance. Test Case – For Loops Every program I ever wrote has at least one loop and often than not I use a For loop for iterating my collections. The following code accesses two dimensional...
Posted by dhelper | with no comments