Back to the Future Revisted
In a previous post, Back to the Future, I was bemoaning the state of software design in industry today. I received a very thorough and thoughtful reply by a colleague who I respect greatly but did not feel comfortable posting to a public forum.
One of my complaints was that even when we use object oriented design, realtime software is rarely written using an object oriented programming language such as C++ or Java. Nearly all realtime and embedded systems software is written in C. My colleague pointed out:
“Tools vs. concepts” :: (DISCLAIMER) A FAVORITE RAILING CONCEPT OF MINE… Just because one is using C++, Java or one of the more esoteric languages to IMPLEMENT a system, doesn’t mean that one has used “Object Oriented” concepts in designing the system, perhaps that is an echo back of what you are saying… similarly, just because one is using C &/+ assembler to implement a system doesn’t mean that one DID NOT use object oriented concepts/design/etc. IN IMPLEMENTING THE SYSTEM!!! Having hailed from roots writing code for missiles in the late seventies/early-eighties and graduating to game programming in the mid-eighties, I can tell you first-hand that some of the best designers I’ve ever worked with wrote their code STRICTLY/ENTIRELY in assembler… regardless of the manner in which they arrived at how things should work/behave. And some of those folks were damn’d prescient with regard to what really made sense… polymorphism wasn’t lost on the really good game designers.
My software roots go back to writing Z80 and PDP11 assembly for networking equipment and I realize that we were using virtual functions and polymorphism in our state machines but just didn’t have that vocabulary. Good design concepts are just good design concepts.
You can see it in the Linux Networking code. The Network Device interface uses function pointers in a way that is much like using virtual functions in C++. Likewise the device interface implements an event notification function that is amazingly similar to the Observer Pattern in Design Patterns: Elements of Reusable Object-Oriented Software by Gamma et. al.
So, using a procedural language like C is not a good excuse for not doing design, even though all the software design books in the library are about object oriented design.







