September 2013
Intermediate to advanced
548 pages
12h 25m
English
In this chapter, we’ll look at a number of techniques that you can use to tune your program, find bugs, and avoid errors.
We use profiling for performance tuning to find out where the hot spots in our programs are. I think it’s almost impossible to guess where the bottlenecks in our programs are. The best approach is to first write our programs, then confirm that they are correct, and finally measure to find out where the time goes. Of course, if the program is fast enough, we can omit the last step.
We use coverage analysis to count the number of times each line of code in our programs has been executed. Lines that have been executed zero times might indicate an error ...
Read now
Unlock full access