CSCE-622 Generic Programming
|Course||CPSC-622 : Generic Programming, MWF 10:20AM-11:10PM CE 203|
|Office hours||By appointment (my office is 416)|
|Teaching Assistant||John Freeman (email@example.com), office hours: Tuesdays and Wednesdays, 2–3PM, HRBB 414D|
In a nutshell
Study of the generic programming approach to design and systematic classification of software components. Techniques for achieving correctness, efficiency, and generality of algorithms, data structures, and memory management. Methods of structuring a library of generic software components for maximum usability are practiced in a significant design and implementation project, or analyzed in a research project.
The main programming tool used in the course is C++, but we take a close look of language constructs for generic programming in several other programming languages, including Generics in Java (or C#), and Haskell, We will also get acquainted with new language features of C++ that improve support for generic programming in C++.
- Note to a prospective student:
If you are thinking of a research career in programming languages, or in such areas of software engineering as reusable software libraries, generic or generative programming etc., you are well advised to take the course. Research in this area is very active: generics in several mainstream languages are evolving constantly, as well as the mechanisms to exploit genericity to change and improve programming practices. After Generic Programming, Programming Language Design (604) in the spring is the next natural choice if you are serious in pursuing research in this field.
The course will have (about) five programming assignments and one final project. The final project is either a large design and implementation project done in a group, or a research project, that can be individual.
Assignments will be managed and turned in electronically (preferably via CSNET). You may be required to demonstrate your programs to the instructor. Some assignments, as well as the final project, will be done in groups of two or three students. You may form groups on your own, but you will be in the same group for the entire semester. For the problem sets, each group will turn in one copy of the assignment, with the names of all group members on it.
Each programming assignment will cover a major course topic and may (will) involve a significant amount of programming. **Do not wait until the night before an assignment is due to start working on it!**
Late work will be accepted, but a penalty of 20% per calendar day late will be assessed. Assignments are due at 11:59PM on their due date, unless otherwise instructed.
Your course grade will be based on assignments (50%), and term projects (50%). Class presentations affect the grading of term projects. After assigning the grade based on the above criteria, not participating in classes can reduce your grade by up to 10 percent points. A perfect attendance is not required, but expect this clause to be in effect if I rarely see you in class.
A grade of 90% or above guarantees an A, 80% or above a B, 70% or above a C, and 60% or above a D.
This grading formula implies that there is no curve; your grade will depend only on how well you do, and not on how well everyone else does. (If everyone does exceptionally badly on some assignment, I may decide the assignment was at fault rather than the students, in which case I'll adjust the grade cutoffs as I deem appropriate. But I won't adjust in the other direction; if everyone gets an A, that's great).
All grade assignments are final—unless there was a mistake made in recording your semester grades or in computing your final grade. If all numbers are correctly recorded and computed, I will not discuss changing the resulting letter grades.
There are situations that may warrant regrading a particular assignment. For example, making addition errors in computing your score, not seeing or recognizing an answer that you gave, or not understanding an answer that you gave. Requests for regrading of assignments must be made within one week after the graded work has been handed back.
Academic Integrity Policy: An Aggie does not lie, cheat, or steal or tolerate those who do. The Honor Council Rules and Procedures are available on the web http://www.tamu.edu/aggiehonor.
Americans with Disabilities Act (ADA) Policy: The Americans with Disabilities Act (ADA) is a federal anti-discrimination statute that provides comprehensive civil rights protection for persons with disabilities. Among other things, this legislation requires that all students with disabilities be guaranteed a learning environment that provides for reasonable accommodation of their disabilities. If you believe you have a disability requiring an accommodation, please contact the Department of Student Life, Services for Students with Disabilities, in Room 126 of the Koldus Building or call 845-1637.
The following is a tentative list of topics discussed during the course:
- Motivation for genericity, software components, reuse
- Some necessary C++ background relevant for generic programming
- The design principles of the STL part of the C++ standard library
- Process of generic programming
- Concept taxonomies in library design
- Concepts as constraints to type parameters
- Performance of generic code (and how to measure it)
- Analyzing language features that support generic programming (we look at languages such as C#, Java, Haskell, …)
- Dissecting the Boost Graph Library
- Metaprogramming (Boost Metaprogramming Library, Expression Templates, MetaOCaml, …)
- Generative programming
- C++ ``concepts'' — constrained generics in C++
Schedule and material
Some of the slides are based on earlier presentations, or other material, contributed by numerous people, in particular, Andrew Lumsdaine, Jeremiah Willcock, Jeremy Siek, Dave Musser, Alex Stepanov, Dave Abrahams, and Doug Gregor.
|Mon, Aug 30||Introduction||Slides 1|
|Wed, Sep 1||Introduction, C++ template features||Slides 2|
|Fri, Sep 3||C++ template features|
|Mon, Sep 6||C++ template features|
|Wed, Sep 8||C++ template features|
|Fri, Sep 10||GP Process, STL||Slides 3 Slides 3 (4up)|
|Mon, Sep 13||STL, discussion of EoP Ch1|
|Wed, Sep 15||STL, Expressing Concepts, Refinement|
|Fri, Sep 17||STL, Iterator Concepts, Algortihms|
|Mon, Sep 20||STL, Container Concepts, discussion of Eop Ch2|
|Wed, Sep 22||Functions and function objects||Slides 4 Slides 4 (4up)|
|Fri, Sep 24||Adaptors|
|Mon, Sep 27||(Discussion of EoP Ch3), Associated types, traits|
|Wed, Sep 29||Traits, Allocators|
|Fri, Oct 1||Approaches to constrained generics|
|Mon, Oct 4||(EoP Ch4), Approaches to constrained generics||Slides 5 Slides 5 (4up)|
|Wed, Oct 6||Approaches to constrained generics|
|Fri, Oct 8||Projects|
|Mon, Oct 11||Andrew Sutton: Inferring concept constraints|
|Wed, Oct 13||John Freeman: C++0x lambda functions|
|Fri, Oct 15||Approaches to constrained generics, F-bounded polym.||Concepts.pptx|
|Mon, Oct 18||(EoP Ch5), Type classes|
|Wed, Oct 20||Type classes, ML Functors|
|Fri, Oct 22||BGL||Slides 13 Slides 13 (4up)|
|Mon, Oct 25||(EoP Ch6) BGL|
|Wed, Oct 27||BGL|
|Fri, Oct 29||BGL|
|Mon, Nov 1||(EoP Ch7) BGL, Metaprogramming||Slides 20|
|Wed, Nov 3||Metaprogramming|
|Fri, Nov 5||Metaprogramming|
|Mon, Nov 8||(EoP Ch8) Metaprogramming|
|Wed, Nov 10||Metaprogramming|
|Fri, Nov 12||Metaprogramming.||Slides 12|
|Mon, Nov 15||(EoP Ch9) Enable_if.|
|Wed, Nov 17||C# and Java generics||Slides 16|
|Fri, Nov 19||C# and Java generics (Project presentation)|
|Mon, Nov 22|
|Wed, Nov 24|
|Fri, Nov 26||Thanksgiving: no class|
|Mon, Nov 29||Project presentations|
|Wed, Dec 1||Project presentations|
|Fri, Dec 3||Project presentations|
|Mon, Dec 6||Project presentations|
- Assignment 1 Due on Tue, 14th of September. This assignment is to be done individually.
- Assignment 2 Due on Fri, 1st of October. This assignment is to be done individually.
- Assignment 3 Due on Fri, 5th of November. This assignment is to be done in pairs (within your project teams).
- Assignment 4 Due on Mon, 22nd of November. This assignment is to be done in pairs (within your project teams).
The projects instruction page.
The main tool you will be needing in this course is a C++ compiler. Get your hands on one by whatever means you wish. I will also ask your returned assignments to come equipped with Makefiles that build your programs; familiarize yourself with make. Also, be prepared to create pdf files by some means; pdf is the format that you are required to return your write-ups in. A handy tool for this is LaTeX (in fact, pdfLaTeX).
Instructions on other software tools we may possibly need will be given later.
Though not following it directly, we will use the book
- Alexander Stepanov, Paul McJones: Elements of Programming
quite a lot, so I recommend getting it.
The following list of books contain useful reference or otherwise related material for the course (but you do not need to acquire them for just this course):
- Andrew Koenig and Barbara Moo: Accelerated C++, Addison-Wesley, 2000.
- Bjarne Stroustrup: The C++ Programming Language, 3rd edition, Addison-Wesley, 1997.
- David Vandevoorde, Nicolai M. Josuttis: C++ Templates: The Complete Guide, Addison-Wesley, 2003.
- Jeremy Siek, Lie-Quan Lee, and Andrew Lumsdaine, The Boost Graph Library Addison-Wesley, 2001.
- Matthew H. Austern: Generic Programming and the STL: Using and Extending the C++ Standard Template Library, Addison-Wesley, 1998.
- David R. Musser, Gillmer J. Derge, and Atul Saini: STL Tutorial and Reference Guide, Second Edition: C++ Programming with the Standard Template Library, Addison-Wesley, 2001.
- David Abrahams and Aleksey Gurtovoy, C++ Template Metaprogramming: Tools and Techniques from the Boost Libraries, Addison-Wesley, 2004.
Date: 2010-11-17 00:50:56 CST
HTML generated by org-mode 7.01trans in emacs 23