Skip to main content

2018 | OriginalPaper | Buchkapitel

6. Languages and Compilers

verfasst von : Jean-Michel Muller, Nicolas Brunie, Florent de Dinechin, Claude-Pierre Jeannerod, Mioara Joldes, Vincent Lefèvre, Guillaume Melquiond, Nathalie Revol, Serge Torres

Erschienen in: Handbook of Floating-Point Arithmetic

Verlag: Springer International Publishing

Aktivieren Sie unsere intelligente Suche, um passende Fachinhalte oder Patente zu finden.

search-config
loading …

Abstract

The previous chapters have given an overview of interesting properties and algorithms that can be built on an IEEE 754-compliant floating-point arithmetic. In this chapter, we discuss the practical issues encountered when trying to implement such algorithms in actual computers using actual programming languages. In particular, we discuss the relationship between standard compliance, portability, accuracy, and performance. This chapter is useful to programmers wishing to obtain a standard-compliant behavior from their programs, but it is also useful for understanding how performance may be improved by relaxing standard compliance and also what traps one may fall into.

Sie haben noch keine Lizenz? Dann Informieren Sie sich jetzt über unsere Produkte:

Springer Professional "Wirtschaft+Technik"

Online-Abonnement

Mit Springer Professional "Wirtschaft+Technik" erhalten Sie Zugriff auf:

  • über 102.000 Bücher
  • über 537 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Maschinenbau + Werkstoffe
  • Versicherung + Risiko

Jetzt Wissensvorsprung sichern!

Springer Professional "Technik"

Online-Abonnement

Mit Springer Professional "Technik" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 390 Zeitschriften

aus folgenden Fachgebieten:

  • Automobil + Motoren
  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Elektrotechnik + Elektronik
  • Energie + Nachhaltigkeit
  • Maschinenbau + Werkstoffe




 

Jetzt Wissensvorsprung sichern!

Springer Professional "Wirtschaft"

Online-Abonnement

Mit Springer Professional "Wirtschaft" erhalten Sie Zugriff auf:

  • über 67.000 Bücher
  • über 340 Zeitschriften

aus folgenden Fachgebieten:

  • Bauwesen + Immobilien
  • Business IT + Informatik
  • Finance + Banking
  • Management + Führung
  • Marketing + Vertrieb
  • Versicherung + Risiko




Jetzt Wissensvorsprung sichern!

Fußnoten
1
This requirement was introduced in C89 and kept in the subsequent C99 and C11 standards. The original Kernighan and Ritchie C [333] allowed regrouping, even with explicit parentheses in expressions.
 
2
The International Standard Organization and the International Electrotechnical Commission are two sister international organizations whose members are, respectively, 163 national standard bodies and 83 national committees.
 
4
VFP stands for “Vector Floating-Point” but the vector mode was removed shortly after its introduction.
 
6
The SPARC architecture has instructions for quadruple precision, but in practice, current processors generate traps to compute the results in software.
 
8
The C11 standard still does not specify a power function with an integer type as the second argument.
 
9
Note, however, that this formalization just comes from an interpretation of the ISO C standard, which is written in plain English. Before version 2.5, CompCert behaved differently from other compilers by not rejecting a lexically invalid program.
 
10
When is_iec559 is true, the C++ standard mandates that infinities and NaNs are available.
 
11
round_style is a constant member. Therefore, it may well be set to the default round_to_nearest style, even if the architecture allows us to change the rounding direction on the fly.
 
Literatur
[51]
Zurück zum Zitat S. Boldo, J.-H. Jourdan, X. Leroy, and G. Melquiond. Verified compilation of floating-point computations. Journal of Automated Reasoning, 54(2):135–163, 2015.MathSciNetCrossRef S. Boldo, J.-H. Jourdan, X. Leroy, and G. Melquiond. Verified compilation of floating-point computations. Journal of Automated Reasoning, 54(2):135–163, 2015.MathSciNetCrossRef
[152]
Zurück zum Zitat F. de Dinechin, E. McIntosh, and F. Schmidt. Massive tracking on heterogeneous platforms. In 9th International Computational Accelerator Physics Conference (ICAP), October 2006. F. de Dinechin, E. McIntosh, and F. Schmidt. Massive tracking on heterogeneous platforms. In 9th International Computational Accelerator Physics Conference (ICAP), October 2006.
[220]
Zurück zum Zitat J. Gosling, B. Joy, G. Steele, G. Bracha, and A. Buckley. The Java Language Specification, Java SE 8 edition. Oracle, 2015. J. Gosling, B. Joy, G. Steele, G. Bracha, and A. Buckley. The Java Language Specification, Java SE 8 edition. Oracle, 2015.
[273]
Zurück zum Zitat International Organization for Standardization. Programming Languages – C. ISO/IEC Standard 9899:1999, Geneva, Switzerland, December 1999. International Organization for Standardization. Programming Languages – C. ISO/IEC Standard 9899:1999, Geneva, Switzerland, December 1999.
[276]
Zurück zum Zitat International Organization for Standardization. Programming languages – Fortran – Part 1: Base language. International Standard ISO/IEC 1539-1:2004, 2004. International Organization for Standardization. Programming languages – Fortran – Part 1: Base language. International Standard ISO/IEC 1539-1:2004, 2004.
[278]
Zurück zum Zitat International Organization for Standardization. Programming Languages – C. ISO/IEC Standard 9899:2011, Geneva, Switzerland, November 2011. International Organization for Standardization. Programming Languages – C. ISO/IEC Standard 9899:2011, Geneva, Switzerland, November 2011.
[279]
Zurück zum Zitat International Organization for Standardization. Floating-point extensions for C – Part 1: Binary floating-point arithmetic. ISO/IEC Technical Specification 18661-1:2014, Geneva, Switzerland, July 2014. International Organization for Standardization. Floating-point extensions for C – Part 1: Binary floating-point arithmetic. ISO/IEC Technical Specification 18661-1:2014, Geneva, Switzerland, July 2014.
[280]
Zurück zum Zitat International Organization for Standardization. Floating-point extensions for C – Part 2: Decimal floating-point arithmetic. ISO/IEC Technical Specification 18661-2:2015, Geneva, Switzerland, May 2015. International Organization for Standardization. Floating-point extensions for C – Part 2: Decimal floating-point arithmetic. ISO/IEC Technical Specification 18661-2:2015, Geneva, Switzerland, May 2015.
[281]
Zurück zum Zitat International Organization for Standardization. Floating-point extensions for C – Part 3: Interchange and extended types. ISO/IEC Technical Specification 18661-3:2015, Geneva, Switzerland, October 2015. International Organization for Standardization. Floating-point extensions for C – Part 3: Interchange and extended types. ISO/IEC Technical Specification 18661-3:2015, Geneva, Switzerland, October 2015.
[282]
Zurück zum Zitat International Organization for Standardization. Floating-point extensions for C – Part 4: Supplementary functions. ISO/IEC Technical Specification 18661-4:2015, Geneva, Switzerland, October 2015. International Organization for Standardization. Floating-point extensions for C – Part 4: Supplementary functions. ISO/IEC Technical Specification 18661-4:2015, Geneva, Switzerland, October 2015.
[283]
Zurück zum Zitat International Organization for Standardization. Floating-point extensions for C – Part 5: Supplementary attributes. ISO/IEC Technical Specification 18661-5:2016, Geneva, Switzerland, August 2016. International Organization for Standardization. Floating-point extensions for C – Part 5: Supplementary attributes. ISO/IEC Technical Specification 18661-5:2016, Geneva, Switzerland, August 2016.
[333]
Zurück zum Zitat B. W. Kernighan and D. M. Ritchie. The C Programming Language. Prentice-Hall, Englewood Cliffs, NJ, 1978.MATH B. W. Kernighan and D. M. Ritchie. The C Programming Language. Prentice-Hall, Englewood Cliffs, NJ, 1978.MATH
[377]
Zurück zum Zitat V. Lefèvre. The Euclidean division implemented with a floating-point division and a floor. Research report RR-5604, INRIA, June 2005. V. Lefèvre. The Euclidean division implemented with a floating-point division and a floor. Research report RR-5604, INRIA, June 2005.
[383]
Zurück zum Zitat X. Leroy. Formal verification of a realistic compiler. Communications of the ACM, 52(7):107–115, 2009.CrossRef X. Leroy. Formal verification of a realistic compiler. Communications of the ACM, 52(7):107–115, 2009.CrossRef
[390]
Zurück zum Zitat T. Lindholm, F. Yellin, G. Bracha, and A. Buckley. The Java TM Virtual Machine Specification, Java SE 8 edition. Oracle, 2015. T. Lindholm, F. Yellin, G. Bracha, and A. Buckley. The Java TM Virtual Machine Specification, Java SE 8 edition. Oracle, 2015.
[434]
Zurück zum Zitat S. Muchnik. Advanced Compiler Design and Implementation. Morgan Kaufmann, 1997. S. Muchnik. Advanced Compiler Design and Implementation. Morgan Kaufmann, 1997.
Metadaten
Titel
Languages and Compilers
verfasst von
Jean-Michel Muller
Nicolas Brunie
Florent de Dinechin
Claude-Pierre Jeannerod
Mioara Joldes
Vincent Lefèvre
Guillaume Melquiond
Nathalie Revol
Serge Torres
Copyright-Jahr
2018
DOI
https://doi.org/10.1007/978-3-319-76526-6_6