Mind the gap - teaching computer and compiler design in lockstep

Mind the gap - teaching computer and compiler design in lockstep

E. Todirica, C. Probst (2014).  Mind the gap - teaching computer and compiler design in lockstep. 10.

In this article we discuss a design-build project based on two courses, a hardware-centric and a software-centric course in the third term of a computer systems engineering study line. In the hardware-centric course, the students learn how to build a processor from the ground up, by implementing it on an FPGA, and learning how a C compiler for this processor works internally. In the software-centric course, they learn how to implement a compiler for a high-level language, a subset of Java, that generates native code for the processor they develop in the hardware course. The students thus explore the rather complex topic of generating executable native code from two directions: in the hardware course bottom-up, and in the software course top-down. Combined, these two course enable deep insights into and better understanding of the processor, the task of compiling, and the languages C and Java.

The overall aim of the courses and the associated project is to teach the fundamentals of how a processor and an embedded computer system work, both from hardware and from a software point of view. They run in parallel for the term, followed by an intensive, 3 week project period, where the students get the loosely defined task to design and build a small computer-based system using the processor developed in the hardware-centric course, and to program an application for it.

Although the project is closely linked to these two courses, many students include topics from other courses in their project. Some groups use knowledge from a course on objected-oriented analysis and design for interaction with a host system, others use knowledge on databases, or from statistics. In an ideal world they would add project-specific support to the Java compiler developed in the software-centric course. However, since the project is so loosely defined, this component is hard to control, and in our view should only be an option.

During the course of the third term we experience a clear first drop of excitement due to the complexity of the topic, which then is overcome by excitement due to the possibilities, and the increased understanding due to the two complementary approaches to explaining both the low-level execution and the high-level languages. Both courses have been re-designed in recent years to accomodate the complementarity.

In this article we present the course construction and discuss dependencies between the two courses, and discuss the general principle of combining complementary courses that cover similar material.

Proceedings of the 10th International CDIO Conference, Barcelona, Spain, June 15-19 2014

Authors (New): 
Edward Alexandru Todirica
Christian W Probst
Pages: 
10
Affiliations: 
Technical University of Denmark, Denmark
Keywords: 
Computer Science
project work
CDIO Standard 5
CDIO Standard 7
CDIO Standard 8
Peer evaluation
Year: 
2014
Reference: 
Appel, A. (2002). Modern Compiler Implementation in Java (2nd Edition ed.). Cambridge University Press. : 
Chu, P. P. (2008). FPGA Prototyping by VHDL examples – Xilinx Spartan-3 Version . Wiley.: 
E. Crawley, J. M. (2007). Rethinking Engineering Education. The CDIO Approach. New York: Springer. : 
Jens Sparsø, T. B. (2011). CDIO projects in DTU's B.Eng. in IT study program. Proceedings of the 7th International CDIO Conference: 
Patel, Y. N. (2004). Introduction to Computing Systems: From Bits and Gates to C and Beyond 2/e. McGraw Hill. : 
Todirica, E. A. (2014, January). Homepage of the Course "HW/SW Programming". Retrieved February 2014 from DTU Compute: http://www.compute.dtu.dk/courses/02321/: 
Go to top