Another win for profiling.

Alan Meyer ameyer2 at yahoo.com
Fri Jul 29 19:44:48 CEST 2011


On 07/29/2011 07:46 AM, Roy Smith wrote:
> It's often said that you shouldn't try to guess what's slow, but use
> profiling tools to measure what's slow.  I had a great example of that
> yesterday.  ...

Yes.

My first experience of profiling was about 25 years ago.  I was 
experimenting with Borland's Turbo Profiler on C code.  I thought to 
myself, What kind of clueless programmer doesn't know where his code is 
spending its time?  How useful could this be?

Then I ran the profiler and found out how clueless I really was.  The 
profiler showed me that I could change one line in a thousand line 
program and cut the run time by 50%.

     Alan



More information about the Python-list mailing list