A couple years ago, I was handed a task I did not know how to do: profile a corporate application and see where the code is spending most of its time. I had a professional tool (Quantify) available to help me do it. It took me weeks to figure out how to use it at a basic level, just enough to confirm what we already suspected: that the bottleneck wasn’t in Mozilla code.
Yesterday, while working with some experimental code, I hit a new perf issue that absolutely should not be happening. (Bug 362694 for anyone interested.) Profiling and performance analysis is something I do so infrequently that I never took the time to really learn how to do it.
Ultimately, I found that there are a lot of free tools available to help me gather data… but this is worse than useless for me because I can’t figure out what the data is saying. PEBKAC. Someone suggested Shark to me for the Mac platform, but I found Shark didn’t capture anything from my XULRunner app. I’m not blaming Shark; I just don’t know how to use it.
So I wouldn’t mind a good written tutorial in profiling analysis from start to finish for Mozilla code. Particularly under the constraint of free or inexpensive tools. I’d write it if I had a clue what I was doing.