Home > On-Demand Archives > Talks >

Modern C++ in Embedded Development: Expressive Compile-Time Computation

Amar Mahmutbegovic - Watch Now - EOC 2024 - Duration: 25:43

Modern C++ in Embedded Development: Expressive Compile-Time Computation
Amar Mahmutbegovic

C++11 made a significant impact on C++, bringing in features such as auto, lambdas, and constexpr. These features modernized language, making it more expressive.

This talk guides embedded developers who dominantly use C for their daily tasks through compile-time evaluation of functions and expressions in C++. It demonstrates language capabilities to generate lookup tables and mathematical signals in compile time while providing expressive abstractions similar to Matlab.

The talk will help embedded developers to better understand modern C++ capabilities, and it will cover the following topics:

  • Constexpr variables, 
  • Constexpr functions, 
  • Operator overloading, 
  • Lambdas, 
  • Templates, 
  • Abbreviated function template. 

The talk aims to demonstrate C++’s compile-time computation capability through a practical example while gradually guiding the audience through the language features needed to build the example.

M↓ MARKDOWN HELP
italicssurround text with
*asterisks*
boldsurround text with
**two asterisks**
hyperlink
[hyperlink](https://example.com)
or just a bare URL
code
surround text with
`backticks`
strikethroughsurround text with
~~two tilde characters~~
quote
prefix with
>

JoeTrainor
Score: 0 | 7 months ago | 1 reply

When would someone use constexpr verse consteval?

amar_mahmutbegovicSpeaker
Score: 0 | 7 months ago | no reply

You would use consteval to enforce compile-time evaluation. Calling consteval function with run-time arguments would result in compile error.
Constexpr functions can be used both with const expressions and run-time arguments.

OUR SPONSORS

OUR PARTNERS