Teaching Introductory Computer Architecture and Programming: What, When, How?

Sunday, 24 January 2010, 14:00 - 17:30, Pisa, Italy
Held in conjunction with:
the 5th International Conference on High-Performance and Embedded Architectures and Compilers (HiPEAC) 2010

Education is the preparation of the future --of those who will carry on the work of the current generation; hence, it is at least as important, if not more important, than current work. University education is provided by highly skilled researchers, who are experts on a number of deep issues. However, this does not always mean that they are good educators, especially at the introductory undergraduate level, where the understanding of fundamental concepts and the acquisition of basic skills is more important than mastering the intricacies of deep issues. This tutorial is intended for those who want to improve their teaching skills, methods, and material.

The tutorial will start with general recommendations that are essential for high-quality teaching --in all subjects. It will then concentrate on how to best teach, at the introductory undergraduate level, the basic topics in the HiPEAC domain --Digital Design, Computer Organisation, and Introductory Programming.

The main part of the tutorial will address the questions of What and When. Which parts of the large material that exists in these areas should be covered, and which parts should be left out? When, and in which sequence should each topic be taught? How and when should we deal with parallelism? An ever recurring theme is bottom-up versus top-down teaching, or combinations of the two. Yale Patt and Sean Halle, the two main speakers, will describe alternative views on what one should do. Avi Mendelson will summarise, synthesize, and lead a one-hour long discussion, with active audience participation, on these important and complex issues. The intended result is for the attendants to be able to use some of the ideas and conclusions that they will hear in order to improve their own teaching. The schedule is as follows:

  • 14:00 - 14:30   Yale Patt: The art of high-quality teaching, especially as applied to introductory computer architecture and programming.
  • 14:30 - 15:10   Yale Patt: The bottom-up approach to teaching introductory computer architecture and programming.
  • 15:10 - 15:40   Coffee Break
  • 15:40 - 16:20   Sean Halle: The top-down approach to teaching introductory computer architecture and programming.
  • 16:20 - 16:30   Avi Mendelson: Summary and Synthesis.
  • 16:30 - 17:30   Discussion, with the active participation of the speakers and the audience - Avi Mendelson, Chair.
Lecturers - Contributors:

Yale Patt is Professor of Electrical and Computer Engineering, and holds the Ernest Cockrell, Jr. Centennial Chair in Engineering, at The University of Texas at Austin. He received the year-2000 ACM Karl V. Karlstrom Outstanding Educator Award, "for great ability, dedication, and success in developing computer science education, and for outstanding achievements as a teacher". He is also the recipient of the: 1996 IEEE/ACM Eckert-Mauchly Award, "for important contributions to instruction level parallelism and super-scalar processor design"; 1995 IEEE Emanuel R. Piore Award (the IEEE Technical Field Medal for Information Processing), "for contributions to computer architecture leading to commmercially viable high performance microprocessors"; 1999 IEEE Wallace W. McDowell Award, "for his impact on the high performance microprocessor industry via a combination of important contributions to both engineering and education"; and 2005 IEEE Charles Babbage Award, "for fundamental contributions to high performance processor design". Yale Patt has authored, with Sanjay Patel, the textbook Introduction to Computing Systems: From Bits and Gates to C and Beyond, which is intended as an introduction to computing for serious students of computer science, computer engineering, and electrical engineering.

Sean Halle is a fearless entrepreneur from Silicon Valley. He founded a fabless chip company around a MIMD-SIMD low-power massively parallel processor for graphics in 1997 (ProSide), then switched over and worked his way up the software engineering foodchain, ending as Chief Software Architect at Nevik. Along the way, he has taught courses on Object Oriented Programming, as well as in-house seminars on emerging technologies at DEC, SRI, and Sun's JavaSoft. Currently he is finishing his PhD on Portable High Performance Parallelism, with a research focus on techniques for "write once, run high performance anywhere" parallel code.

Avi Mendelson is Adjunct Professor in the CS and EE Departments, Technion, and also works at the Microsoft R&D Center in Israel. Prior to joining Microsoft, he was with Intel for 10 years, where he served as a Senior Researcher and Principal Engineer in the Computer Architecture Group. While with Intel, he was the Chief Architect of the CMP (multi-core-on-chip) feature of the first two dual core processors that Intel developed, and is thus recognized as one of the key people to start the CMP revolution in Intel and later on in the entire industry. Now, at Microsoft, he continues his research in the relevant area and manages the Academic Relations of Microsoft Israel with Academia.

This tutorial is organized by Manolis Katevenis (FORTH), Koen De Bosschere (Ghent Univ.), Mats Brorsson (KTH), and the HiPEAC Task Force on Education and Training

Description of the Lectures:

Yale Patt: The art of high-quality teaching (especially as applied to introductory computer architecture and programming): After more than 40 years as a professor, all of which in the trenches as well as doing research and consulting, I have come up with a number of thoughts on how to teach. This talk will discuss as many of them as there is time for. I note that the organizer titled this talk "The Art of High Quality Teaching." I had nothing to do with coming up with the title, although I believe it is brilliantly on point. Teaching is more art than science, although science can certainly help. But the more one does it, the more case studies one experiences, the better one gets at it, and that is a characteristic of an art. This talk is intended to be independent of the top-down vs bottom-up discussion which will come later. I plan to discuss things that apply equally to both. In fact, one of the problems with education today is that too many have forsaken both top-down and bottom-up in favor of top-up, and that is particularly problematic. I will start with my Ten Commandments for Good Teaching, because good teaching starts with the mindset of the instructor when he enters the classroom. I also hope to get into why high tech can be the enemy of education, where professors should put their laptops, what I think of today's fashionable "active learning" and "pair programming" notions, what I think of study groups, who should teach this material, and why there is no substitute for a student designing something wrong, figuring out why, fixing it and seeing the working final result.

Yale Patt: The bottom-up approach to teaching introductory computer architecture and programming: My passion in teaching is to remove magic. I think this is best done by starting at a level of abstraction that every two-year-old understands, and continually building on what the student knows, continually raising the level of abstraction. We start with the transistor as wall-switch, move to logic circuits, then memory, finite state machines, then the computer and programming, first in machine language, then assembly language, finally C. I/O is physical, a keyboard and monitor. Students are introduced to system service routines and interrupt processing. Parallelism appears naturally, because, with respect to hardware, parallelism is pervasive. ...and not scary. I introduced this model in the freshman curriculum at Michigan in 1995, and have taught it ten times to more than 3000 students. To not teach it every semester, I wrote a textbook with my former PhD student, Sanjay Patel: "Intro to Computing Systems: from bits and gates to C and beyond". More than 100 schools have used the book, and the number is growing. More than 1000 schools have not. The book is also available in Chinese and Spanish. Syllabi, handouts, email archives, etc. are on my web site. Click on EE 306 for the desired semester. In this talk, I will quickly take you through EE 306. I hope to show why this paradigm makes sense, why the correct name of the paradigm is "motivated bottom-up," not simply bottom-up, why the correct ISA is the LC-3, and why this course belongs in the freshman year of every computer science or engineering student's education.

Sean Halle: The top-down approach to teaching introductory computer architecture and programming: The assumptions upon which Introduction to Architecture and Programming have been based in the past are no longer valid. Most importantly, it is a fallacy to teach programming based upon a model of a physical machine. Out-of-order pipelines, modern compilers, higher-level languages, and now the move to portable high-performance parallelism have divorced code, even C code, from any notion of performance other than the number of memory accesses. Due to compilers and out-of-order pipelines, a knowledge of registers is meaningless at the level of C code. Further, PHPP (Portable High-Performance Parallelism) requires code to be divorced from any notion of processor architecture other than that of multiple memory spaces. Therefore, future programmers should be taught only a simple model of the processor, as a memory-to-memory device.

The final PHPP languages have not settled out of the dust yet, but fundamentally, due to the constraints of both being portable across parallel architectures and being high performance on each, such languages will have no notion of thread, nor of communication primitive. However, they will have the notion of scheduler, the notion of work-unit (aka task aka job), and the notion of dependency.

Therefore, in this talk, I examine the old assumptions, show how they are no longer valid, propose a simple memory-to-memory processor model that captures the elements that still matter, and propose that an introduction to architecture and programming only give that simple processor model plus a simple machine model indicating the cache levels, the peripheral bus, and the network. I further propose that programming be taught from the outside-in: start with the simple machine model at one end, and at the other end the use-case method of specifying applications, then proceed moving in-ward from those two end-points.

Outside-in shows how languages layer on top of the machine model at one end, and at the other shows how algorithms and abstract data types fit to the patterns in use-cases. It then joins the two ends by implementing the algorithms and abstract data types in terms of a language. The introductory course should make heavy use of libraries that hide most of the machine details. This is because in the real world, most programmers do exactly that. Finally, throughout the course, any place that dependencies arise they should be pointed out:

  • In the basic machine model a dependency is introduced any time different instructions access the same memory location.
  • In the language, a dependency is introduced each time the same variable is used, or each time the same memory location is accessed via a pointer.
  • In an algorithm, a dependency is any communication between data-structures.
  • In an abstract data-type, a dependency is introduced any time state caused by one access to an instance is modified or read by a different access.
  • In the use-cases, a dependency is introduced any time an action in one portion of a use-case has an effect on any other action in any portion of any use-case.
The essence of parallelism is dependencies. Therefore, teaching dependencies at all the different levels is the best preparation for parallel programming.