Technologies de l'information - Langages de programmation, leurs environnements et interfaces logicielles système - Rapport technique sur les performances du C++

Logo
CSA Group
Organisme d'élaboration de normes:
Programme de travail:
Numéro de référence:
CAN/CSA-ISO/IEC TR 18015:12 (R2016)
Catégorie de norme:
Norme nationale du Canada - Adoption d'une Norme internationale
Type d’activité d’élaboration de normes:
Confirmation
Code ICS:
35.060
Statut:
En cours d'élaboration
Date de début de la période de commentaires OEN:
Date de fin de la période de commentaires des OEN:
Affiché le:

Porté:

Champ d’application

The aim of this Technical Report is:

  • to give the reader a model of time and space overheads implied by use of various C++ language and library features,
  • to debunk widespread myths about performance problems,
  • to present techniques for use of C++ in applications where performance matters, and
  • to present techniques for implementing C++ Standard language and library facilities to yield efficient code.

As far as run-time and space performance are concerned, if you can afford to use C for an application, you can afford to use C++ in a style that uses C++s facilities appropriately for that application.

This Technical Report first discusses areas where performance issues matter, such as various forms of embedded systems programming and high-performance numerical computation. After that, the main body of the Technical Report considers the basic cost of using language and library facilities, techniques for writing efficient code, and the special needs of embedded systems programming. Performance implications of object-oriented programming are presented. This discussion rests on measurements of key language facilities supporting OOP, such as classes, class member functions, class hierarchies, virtual functions, multiple inheritance, and run-time type information (RTTI). It is demonstrated that, with the exception of RTTI, current C++ implementations can match hand-written low-level code for equivalent tasks. Similarly, the performance implications of generic programming using templates are discussed. Here, however, the emphasis is on techniques for effective use. Error handling using exceptions is discussed based on another set of measurements. Both time and space overheads are discussed. In addition, the predictability of performance of a given operation is considered.

The performance implications of IOStreams and Locales are examined in some detail and many generally useful techniques for time and space optimizations are discussed.

Raison d’être du projet

Raison d’être du projet
To review the Standard within the required 5 year period

Note : L’information ci-dessus a été recueillie et est diffusée par le Conseil canadien des normes (CCN) pour les besoins de son système de notification centralisé et transparent pour l’élaboration de nouvelles normes. Le système permet aux organismes d’élaboration de normes (OEN) accrédités par le CCN et aux membres du public d’être informés des nouveaux travaux d’élaboration de normes au Canada. Il donne aussi aux OEN accrédités la possibilité de repérer et de résoudre les cas de doubles emplois éventuels dans les normes et les travaux de normalisation.

Les OEN sont eux-mêmes responsables du contenu et de l’exactitude de l’information présentée ici. Cette information n’existe que dans la langue dans laquelle elle a été fournie au CCN.