Abstract
High-order matrix or vector expressions tend to be penalized by the use of huge temporary variables. Expression templates is a C++ technique which can be used to avoid these temporaries, in a way that is transparent to the user. We present an Ada adaptation of this technique which — while not transparent — addresses the same efficiency issue as the original. We make intensive use of the signature idiom to combine packages together, and discuss its importance in generic programming. Finally, we express some concerns about generic programming in Ada.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Luca Cardelli and Peter Wegner. On understanding types, data abstraction, and polymorphism. Computing Surveys, 17(4):471–522, December 1985.
Alexandre Duret-Lutz, Thierry Géraud, and Akim Demaille. Design patterns for generic programming in C++. In Proceedings of the 6th USENIX Conference on Object-Oriented Technologies and Systems (COOTS’01), San Antonio, Texas, USA, July 2001. To appear.
Ulfar Erlingsson and Alexander V. Konstantinou. Implementing the C++ Standard Template Library in Ada 95. Technical Report TR96-3, CS Dept., Rensselaer Polytechnic Institute, Troy, NY, January 1996.
Geoffrey Furnish. Disambiguated glommable expression templates. Computers in Physics, 11(3):263–269, May/June 1997. Republished in [5].
Geoffrey Furnish. Disambiguated glommable expression templates. C++ report, May 2000.
Erich Gamma, Richard Helm, Ralph Johnson, and John Vlissides. Design patterns–Elements of reusable object-oriented software. Professional Computing Series. Addison Wesley, 1995.
Scott W. Haney. Beating the abstraction penalty in C++ using expression templates. Computers in Physics, 10(6):552–557, Nov/Dec 1996.
Intermetrics, Inc., Cambridge, Massachusetts. Ada 95 Rationale, January 1995.
Alexander V. Konstantinou, Ulfar Erlingsson, and David R. Musser. Ada standard generic library. source code, 1998.
Brian McNamara and Yannis Smaragdakis. Static interfaces in C++. In First Workshop on C++ Template Programming, Erfurt, Germany, October 10 2000.
David R. Musser, editor. Dagstuhl seminar on Generic Programming, SchloβDagstuhl, Wadern, Germany, April–May 1998.
David R. Musser and Alexandre A. Stepanov. Generic programming projects and open problems. 1998.
Nathan C. Myers. Traits: a new and useful template technique. C++ Report, 7(5):32–35, June 1995.
Jeremy Siek and Andrew Lumsdaine. Concept checking: Binding parametric polymorphism in C++. In First Workshop on C++ Template Programming, Erfurt, Germany, October 10 2000.
Alex Stepanov. Al Stevens Interviews Alex Stepanov. Dr. Dobb’s Journal, March 1995.
Alex Stepanov and Meng Lee. The Standard Template Library. Hewlett Packard Laboratories, 1501 Page Mill Road, Palo Alto, CA 94304, October 1995.
Todd Veldhuizen. Using C++ template metaprograms. C++ Report, 7(4):36–43, May 1995. Reprinted in C++ Gems, ed. Stanley Lippman.
Todd L. Veldhuizen. Expression templates. C++ Report, 7(5):26–31, June 1995.
Todd L. Veldhuizen. Using C++ trait classes for scientific computing, March 1996.
Todd L. Veldhuizen. Arrays in blitz++. In Proceedings of the 2nd International Scientific Computing in Object-Oriented Parallel Environments (ISCOPE’98), Lecture Notes in Computer Science. Springer-Verlag, 1998.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2001 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Duret-Lutz, A. (2001). Expression Templates in Ada. In: Craeynest, D., Strohmeier, A. (eds) Reliable SoftwareTechnologies — Ada-Europe 2001. Ada-Europe 2001. Lecture Notes in Computer Science, vol 2043. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-45136-6_15
Download citation
DOI: https://doi.org/10.1007/3-540-45136-6_15
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-42123-8
Online ISBN: 978-3-540-45136-5
eBook Packages: Springer Book Archive