The Art of Profiling Using Intel VTune Amplifier, Part 8 (Final)

Part 1, Part 2, and Part 3 of this series provided an introduction to profiling and showed how to setup VTune. The first optimization was discussed in Part 4, in which the number of times printf is executed is reduced. The second optimization was discussed in Part 5, in which strlen got replaced with a much cheaper alternative. The third optimization was discussed in Part 6, in which the amount of computation required to report progress is reduced. The third optimization was discussed in Part 7, in which the function do_pswd was inlined into its caller. The following chart shows by how much each optimization improved password cracking throughput. Continue reading

Advertisements

The Art of Profiling Using Intel VTune Amplifier, Part 7

Previous parts of this series can be found at the following links: Part 1, Part 2, Part 3, Part 4, Part 5, and Part 6.

In Part 6, execution time was improved by 14% and the password cracking throughput became around 150 million passwords per second. Recall from Part 1 that the baseline throughput was around 3 million passwords per second. We have come a long way and we can still do more with the help of VTune. Continue reading

The Art of Profiling Using Intel VTune Amplifier, Part 4

In previous parts of this series, I discussed how to set up a VTune Basic Hotspots analysis to profile the target program. By quickly going through the program, you would notice that there is a significant loop at line 88 in the gen_pswd function. Therefore, one might think that gen_pswd is the hotspot. However, the results reported by VTune says otherwise. Make sure that you are on the Hotspots by CPU Usage viewpoint to follow this article. Continue reading

The Art of Profiling Using Intel VTune Amplifier, Part 3

In Part 1 and Part 2 of this series, I discussed the fundamentals of profiling and provided an introduction to VTune. Now it’s time to create, configure, and run an analysis. Since we are interested in finding performance hotspots, we have two analysis types to choose from: Basic Hotspots and Advanced Hotspots. The former uses time-based sampling and the latter uses event-based sampling. Throughout this series, I’ll use both of them starting with Basic Hotspots. In a real world scenario, if you can use Advanced Hotspots, then you can just use that instead and enjoy the smaller sampling interval and lighter overhead. Continue reading