With the ending of Moore's Law and the rise of multicore systems, programmers from across the industry are increasing forced to develop and maintain highly performance sensitive software. For C++, a language frequently used for performance sensitive projects, benchmarking and performance analysis is especially important. Developing good benchmarks can be tricky; gathering and analyzing data from benchmarks can be an even greater challenge.
This talk will discuss techniques and best practices for writing C++ benchmarks using facilities from the standard library and Boost. We'll also cover the development of performance unit/regression tests. We'll discuss the statistical best practices for gathering data, as well as techniques for benchmarking a variety of different metrics - time, memory, algorithmic complexity, etc.
The main topics which will be covered:
* Statistical Best Practices (dealing with uncertainty, achieving statistical confidence, how to sample) * Time-Based Benchmarking (best practices for timing, derived time-based metrics) * Non-Time-Based Benchmarking (memory, algorithmic complexity in time and space, etc) * Techniques for C++-specific Performance Metrics (counting copies/moves, allocator tricks) * Converting Benchmarks into Tests