Integration Watch: A smart programming project
February 1, 2010 —
(Page 1 of 2)
Related Search Term(s): virtual machines
One of the most common questions posted in the programming section of Reddit consists of asking for suggestions for interesting projects to develop. I know the feeling of this predicament—having the skills and needing a meaty problem to solve.
Many years ago, when I was young and the world was bright with possibilities, and programming—that extraordinary activity by which worlds entirely of my own imaginings are created—had the seductive appeal of magic, I read a set of articles in Byte magazine that transformed my view of what was possible. It was late 1985, and Byte was running a series of pieces written by Jonathan Amsterdam about how to create a virtual machine that implemented a virtual processor, followed by a companion set of articles on writing a simple compiler.
These articles arrived at a perfect time in my life. I had just mastered C (after having made a living for several years as a COBOL jockey) and I was looking for system-level software to write. Amsterdam’s VM, assembler and compiler were a perfect project, and by slowly implementing the system he described during the course of the following year, I learned a tremendous amount.
We have all experienced the surge when a program first runs correctly. But few explosions of beta-endorphins and adrenaline can match the one that pours over you when a program you wrote assembles to an executable that runs correctly on a VM you wrote. The multiple layers of joy and satisfaction lift you into a high that lasts for days. Due to time demands, I never went much past this point, but I saw the promised land and knew I could get there.
One limitation at this pre-Internet time was that Amsterdam’s articles, although long, were perforce too short to do justice to the topic. I had to extrapolate portions. Fortunately, I was friendly with a compiler writer who could point me in the right direction when I came to unexpected crossroads.
The value to me of the project cannot be overstated. By having worked at these various low levels, I had an uncommon feel for how compilers and operating systems enabled my code to work. I also had detailed knowledge of how linkers and libraries work. All this was very useful for writing software in C, and it retained much of its value when the world shifted to runtime environments such as the JVM and .NET.