Schulungen

C++ training — designing functions the right way

by Dr Matthias Kretz (GSI, Darmstadt)

Europe/Berlin
SB3 1.239a Schulungsraum IT (GSI)

SB3 1.239a Schulungsraum IT

GSI

Description

All seats are taken, please follow the link below to announce your interest and we'll see what we can do.

Designing APIs is the daily bread of software development. Every new function is an interface that is used internally or even externally. APIs are a central part of how readable and maintainable a code base is.

As C++ developers we have many choices for functions. We can use non-member functions or member functions. We can make functions pure (output depends only on function arguments) or not. We can use virtual functions or opt for generality at compile-time through templates. Function arguments can be passed via const reference, non-const reference, by value, as pointer, and since C++11 as rvalue reference. And for return values we can choose between out-parameters and the actual return statement of the language.

So many choices can make it hard to choose the right design.

In this one day training we'll look at the motivation for having those choices and at the implications for software design and the impact on optimization and performance. There will be just enough theory presented to enable participants to practice different approaches in small teams. After this day you should be more confident in choosing a certain design and be able to produce more intuitively understandable code.

the instructor:

  • 17 years of C++ experience
  • member of the ISO C++ committee
  • former KDE core-developer, responsible for significant parts of the KDE library APIs
  • PhD in computer science on extending C++ for explicit, portable, and scalable SIMD programming
  • submitter of ~70 C++ compiler bug reports

The room is not very large, and supporting the exercises requires a moderately sized audience. So the number of participants is limited to 30. If no seats are left, please use https://indico.gsi.de/conferenceDisplay.py?confId=6008 to announce your interest.

Slides
Participants
  • Ahmed Ali
  • Alexey Rybalchenko
  • Dennis Klein
  • Florian Uhlig
  • Hamda Cherif
  • Hanna Malygina
  • Ina Syndikus
  • Jan Glorius
  • Maksym Zyzak
  • Matthias Hoek
  • Nazila Divani Veis
  • Olga Bertini
  • Philipp Munkes
  • Pierre-Alain Loizeau
  • Radoslaw Karabowicz
  • Sebastian Heil
  • Susovan Das
  • Valentina Akishina
  • Viktor Klochkov
  • Volker Friese
  • Yadi Wang