I'm interested in compiling a list of c ++ features that are not suitable for use in embedded systems ( And people who may be the reason to recommend C + C) If you know why, try to add or why others should answer.
It is for a start (only one I know)
- Dynamic polymorphism, why not know, but someone said that it is "expensive" Some special features require run-time support, so if you remember the necessary support, then you should avoid those features.
- Dynamic memory allocation
- In particular, the following features require additional run-time support:
- Exceptions < Li> RTTI
- Virtual Heritage (A little bit unsurprising about this one)
People also usually mention templates, but they only provide an advanced macro feature - so that you can easily use them in the embedded system. Still, you can avoid them, because after compiling they can proceed to code bloat.
Your embedded system should come with documentation, if there is, run-time support is available for C ++ (and otherwise).
Comments
Post a Comment