Training and Consulting

Herb has limited availability for private on-site seminars and project problem-solving at your company. This page lists typical services and courses. For more information or to inquire about availability, please contact Herb directly.

Consulting services include:

  • Customized training in all aspects of C++ and concurrency.
  • Review of systems architectures.
  • Review of object-oriented designs to be implemented in C++ or other languages.
  • Code walkthroughs and reviews.
  • Code tuning; identification and correction of performance bottlenecks.
  • Development and/or review of coding guidelines.

The following are some frequently requested courses and topics, and related instructor qualifications.

Effective Concurrency (2 to 4 days)

Herb is the author of the popular Effective Concurrency article series and the forthcoming book Effective Concurrency. Material for a given length of course can be drawn from the following topic menu, which together covers four solid days.

  • Overview: the changing hardware landscape in a nutshell; the three pillars; how many cores are you coding for
  • Fundamentals: overview of primitives: threads, thread pool, lambdas, futures, locks, atomics; think in transactions: locked blocks, safety, robustness; prefer structured/bounded lifetimes: locks, tasks; avoid overheads: context/domain switching, cost of unrealized concurrency; understand the nature of deadlock: not just mutexes, any waiting/blocking cycle
  • Agents and Isolation: basic tools: threads, messages; review history of threading: single, cooperative, preemptive, truly concurrent; common problematic constructs: the ____ thread, the GUI thread; prefer active objects: increase abstractions, avoid using raw threads, helper classes to automate; using agents for performance: pipelining
  • Machine Architecture: fundamentals: bandwidth vs. latency, memory vs. CPU, Little’s Law, pipelining, cache, analyzing CPU profiles of cache misses; effects on code correctness: memory model, sequential consistency, legal and illegal transformations, object layout considerations, a general pattern to avoid, conditional locking / speculative lock elision; effects on code performance: locality matters, access patterns matter even more, hardware considerations
  • Migrating to the New Free Lunch: understanding scalability: 1-core, K-core, N-core; choosing data structures: ones that are concurrency-friendly vs. concurrency-hostile; coping with different semantics: parallelizing algorithms can change their meaning, how to regain stronger semantics when needed; superlinear scalability; interruption
  • Correct Use of Locks: think in transactions: nested transactions, lock reacquisition (safe vs. unsafe), when invariants must hold; how to avoid race conditions: associate data with locks, helper classes to automate; how to avoid deadlocks: apply lock hierarchies, other lock ordering, helper classes to automate; how to avoid composability problems: combining modules/plugins/extensions safely
  • Writing Robust Lock-Free Code: the tools: atomic variables, transactional thinking; Double-Checked Locking pattern: example and analysis, why no longer broken; Producer/Consumer pattern variations: using locks, locks + lock-free for different phases, fully lock-free using mailboxes; implementing a singly linked list: implementing find/insert_at_front/pop, problems and how to avoid them; config_map: locks + atomics together to satisfy a specific lazy initialization requirement

Performance optimization and efficiency, including must-know machine architecture and the costs of code on modern hardware (1 to  1.5 days)

Covers optimization issues from temporaries and inline to single- vs. multi-threaded optimizations and how to optimize build times by managing #include dependencies. Also covers the important things to understand about the complexity of today’s commodity hardware, the ever-deepening memory hierarchy and the memory wall, and the effects on your program’s correctness (e.g., memory model effects) and performance (e.g., memory wall and cache effects).

Herb was one of the designers of the C++11 memory model, and directly involved in specifying the C++11 atomic operations and thread/future library features in the standard.

Software and the concurrency revolution (90 min to .5 day)

Covers the reason for the industry sea change to multicore and manycore hardware, and provides a clear and authoritative description of what this means for how we must write concurrent (e.g., multithreaded) software today and from now on.

Author of the widely-cited article The Free Lunch Is Over that coined the term “concurrency revolution” to describe the move to parallel hardware, and its sequel Welcome to the Jungle on the heterogeneous and cloud parallel sea change, Herb is frequently asked to keynote software conferences on this topic. He is also an active member of groups at Microsoft and in the broader industry that are working on parallel programming systems designs.

Writing robust concurrent code (.5 to 1 day)

Concurrency is “the” must-know item for the next decade in any code where CPU performance is important, because from now on only well-written concurrent applications will be able to exploit the CPU power in commodity hardware. Covers important design principles and best practices for multithreading and shows how to write code to implement them using C++11 and upcoming standard features. Whereas the first C++ standard in 1998 didn’t even have the notion of threads, the new C++ standard continues to add strong support for concurrency, including useful libraries for atomic operations, threads and thread pools, locks, futures, and other important features that from now on are essential knowledge for C++ and other performance-oriented programmers.

Herb was directly involved in specifying the C++11 atomic operations and thread/future library features, and was influential in their design and presence in the standard.

Using C++ effectively on modern platforms and environments (chalk talks on selected topics on request) (various)

From garbage collection to multithreading, from selecting among multiplatform compilers to writing C++ code for .NET, from organizing distributed systems to making effective use of the latest community libraries like Boost and Loki while avoiding their pitfalls – Herb’s broad experience with the most popular compilers and libraries and deep familiarity with all the latest C++ standards can help you on your project today.

In addition to serving as chair of the ISO C++ standards committee, Herb is a contributor of a number of features now in ISO Standard C++11. He is also the language lead architect of C++/CLI, the Ecma standard extensions to ISO C++ for programming on .NET (ISO CLI); C++/CX, the extensions for modern WinRT development on Windows 8 and Windows Phone 8; and C++ AMP, the extensions for using a GPU as a compute accelerator from C++.

C++ Coding Standards (readily customizable to target topics of principal interest to your team) (.5 to 2 days)

Covers an overview and selected topics drawn from the book C++ Coding Standards, including organizational and policy issues; design style; coding style; functions and operators; class design and inheritance; construction, destruction and copying; namespaces and modules; templates and genericity; error handling and exceptions; STL containers and algorithms; and type safety.

Herb is the author (with Andrei Alexandrescu) of the authoritative book C++ Coding Standards that sets out definitive practices and guidelines for writing correct and robust C++ code.

Using the STL effectively  (1 to 2 days)

Covers in-depth explanations of STL containers, iterators, algorithms, functors, allocators, etc., how they are designed, and how to use them effectively.

Herb has over 15 years’ experience in using the STL in production code. He led one of the first commercial development projects in the world to use the STL, starting at the same time as the STL’s acceptance into the ISO C++ draft standard in 1995-1996. (It was a solid foundation; that software project was highly successful, shipped many major releases, and is still being actively maintained and extended today.)

Using the new C++11 and Boost libraries effectively (1 day)

Covers key new features in the ISO C++0x standard library, including smart pointers (std::shared_ptr and std::weak_ptr) and hash-based containers (std::unordered_set, std::unordered_map). Also covers selected important features in the portable Boost open source libraries, including boost::variant and boost::any, boost::multi_index, and boost::format. This course goes beyond explaining the libraries, and gives practical guidance on how to use them effectively, and a liberal dose of context and commentary on their tradeoffs and design.

Besides being an active participant of the ISO C++ committee during the time many of these features were added to C++11, Herb has also personally implemented some of these facilities and intimately understands their implementations and requirements.

Writing robust code: Patterns for exception safety and solid code (1 to 1.5 days)

Covers how to understand exception safety and how to write exception-safe code, and why this matters whether or not you use exceptions (because the same principles apply to using error codes).

Herb is the primary popularizer of the Abrahams exception safety guarantees in his books Exceptional C++, More Exceptional C++, and Exceptional C++ Style, and the coauthor of the landmark book C++ Coding Standards that sets out definitive rules and guidelines for writing correct and robust code, including robust failure designs, and patterns and best practices for the design and implementation of error handling.

Writing robust, reusable, and extensible C++ libraries using templates and namespaces (.5 to 1 day)

Covers advanced template issues and techniques, namespaces issues and correct packaging, policy-based design, and how to write for supportability and maintainability.

Design patterns and policy-based design  (.5 to 1 day)

Covers why patterns matter and how to apply them, and specific key design patterns including Factory, Visitor, Singleton, and variants on applying and implementing each of them, including a look at applying policy-based design using C++ templates for Singleton and strings.


Other topics are available upon request.