7

I was reading this article: A Critique of Common Lisp and finding it hard to make out the precise definition of "stock-hardware machine" and its difference with "micro-coded" machines. I tried to search for a precise definition of the former to no avail.

What I currently construe stock-hardware machine to be is that, it refers to the computer chip-set commonly available in the market (without much customization).

So given that I would like to ask, what is meant by a stock-hardware machine (in the context of the paper) and how does it differ from a micro-coded machine?

Rainer Joswig
  • 2,240
  • 13
  • 17
Bleeding Fingers
  • 343
  • 1
  • 12

3 Answers3

15

In the context of the paper you linked, the words "micro-coded machine" would almost certainly refer to a Lisp Machine.

At the time Lisp was beginning to get a foothold, it was hoped that it would be run (in the general case) on machines that were designed specifically to execute Lisp instructions, rather than computers with a more general instruction set intended to be used with compilers and interpreters for any language.

Microcode is what happens underneath the actual processor instructions. The processor that you are using to read this right now has machine instructions that are almost certainly implemented in some sort of microcode. But at that time, there were probably machines that

  1. Implemented machine instructions in hardware; that is, logic gates, and
  2. Machines that implemented advanced processor instruction sets (Lisp being one example) in microcode.

The former type would have been referred to as "stock hardware." The paper's point, of course, is that any machine designed specifically to execute Lisp instructions directly would have been much better at executing Lisp programs than a machine which required translation of the Lisp instructions to some other instruction set.

At the time the paper was written, this distinction would have been very important, because there were unavoidable memory and processor constraints that no longer exist today.

Robert Harvey
  • 200,592
11

Stock hardware basically means "not customized," as you surmised. Which customizations it refers to depends on the context. In the context of the paper, it means a computer which is not micro-codable. Micro code is to machine code as assembly is to a high-level language. It breaks down each instruction into smaller parts. On most processors, the microcode is completely unchangeable, even by assembly programmers, because it is baked into ROM at the fab. On some supercomputers you can change it. The authors are arguing that Common LISP isn't as efficient on computers where the micro code cannot be customized.

Karl Bielefeldt
  • 148,830
2

In the mid 70s (almost 40 years ago) a few Lisp Machines started to appear. Xerox (PARC) and MIT were developing them. Later Symbolics, LMI, TI and some others. Xerox was using one of their typical bit-slice processors and MIT developed a custom processor (CONS and then the CADR). The Xerox processor was used in a computer which also could run their office software suite and the Smalltalk software. The Xerox processor was using different instruction sets for each. The instruction sets of the processor was programmed in microcode. The MIT Lisp machine also had a processor, which could be programmed in microcode - but it was only used for Lisp. At that time processors were not microprocessor CPUs like today, but one or several boards which make a single CPU. Most computers during the 70s capable of running Lisp were time-shared mainframes or so-called mini-computers (often machines from DEC). Workstations or powerful personal computers did not exist then. The Lisp Machines were designed to be the first personal workstations (single user, no time-sharing, large address space, bitmap display, graphics, mouse, network, ...). To run Lisp efficiently with the processor technology at that time, they needed customized instruction sets. We are talking about early machines with around 1 MB RAM, virtual memory on disk, and less than 1 MIPS (million instructions per second).

The microcoded machines had specially crafted instruction sets to support the execution of Lisp (stack architecture with stack instructions, generic arithmetic, fast function calls, Lisp datatypes, GC support, ...). In the case of the MIT Lisp Machine, the hardware itself also had extensions (like special memory word widths).

The stock-hardware computers were using CPUs like the DEC VAX, Motorola 68k, Intel 86 and later SPARC, POWER, MIPS, ALPHA and many others. These computers used the CPUs like they came from the manufacturer (DEC, Motorola, Intel, IBM, ...). Beyond simple bug fixes (and Lisp developers found several bugs in CPUs) there was no special adaption of the instruction set of these computers while they were running Lisp. Some of them even might have been able to have loadable microcode - but it was not used for Lisp.

The microcoded Lisp CPUs allowed very simple instruction sets and thus a relatively simple Lisp compiler. Additionally some variants allowed to compile simple Lisp functions to microcode. The MIT used a custom CPU, because they wanted a large address space for Lisp, compact code and quick execution for the first personal workstations. A combination which was not available on the market at that time (1970s/ early 80s). Note that these CPUs appeared before Common Lisp (which was first published in 1984). Over time the manufacturers moved the CPUs through different technologies and different Lisp versions. Thus they added support for object-oriented programming (Flavors, CLOS) and logic programming to the instruction sets. It was not unusual for a new Lisp release to also come with an improved microcode with new/improved instructions. Later TI and Symbolics developed microprocessors - single-chip CPUs for Lisp. At least the Symbolics chip was not designed to support loadable microcode.

Summary:

microcoded machines are computers with either bit-slice CPUs or special Lisp cpus with special instruction sets for Lisp.

stock-hardware machines are computers with typical commercial CPUs, as they were designed by the manufacturer - without special Lisp support. Of the later stock hardware machines only the SPARC architecture contains a very tiny amount of support for Lisp (and Smalltalk).

Rainer Joswig
  • 2,240
  • 13
  • 17