Microprogramming

Microprogramming is a technique for implementing processor control logic by storing sequences of microinstructions in a control store, read one per clock cycle to assert control lines, introduced by Maurice Wilkes in 1951.

What Is Microprogramming?

Microprogramming is a technique for implementing the control logic of a processor by storing sequences of low-level control signals, called microinstructions, in a dedicated memory called the control store. Rather than hardwiring the control logic in combinational circuits, a microprogrammed control unit reads one microinstruction per clock cycle from the control store and uses its bit fields to assert the control lines that govern register transfers, arithmetic unit operations, and bus connections. The technique was introduced by Maurice Wilkes of Cambridge University in 1951, who described an implementation using a diode matrix and recognized that processor control could be structured like a program. Microprogramming belongs to the broader field of computer architecture and became a dominant design approach from the 1960s through the 1980s.

The motivation for microprogramming was practical: it made processor design more systematic and easier to verify, and it allowed the same hardware to support different instruction set architectures by reprogramming the control store. Manufacturers could offer compatible product families at different performance points by varying the microcode rather than redesigning the hardware.

Control Store and Microinstructions

The control store is a fast read-only or writable memory that holds the microprogram. Each location contains one microinstruction, a binary word whose individual fields or bits directly activate control signals inside the processor, such as enabling a specific ALU operation, gating a register onto a bus, or writing a result to a destination register. The width of a microinstruction word depends on how many independent control signals exist; a processor with 50 independent control points would require microinstruction words of at least 50 bits in an unencoded design. A next-address field within each microinstruction specifies the location of the following microinstruction, allowing the microprogram to branch based on condition codes or instruction op-codes. The structure of the original Wilkes control unit design is documented in Mark Smotherman's detailed historical survey of microprogramming development.

Horizontal and Vertical Encoding

Two encoding philosophies define the design space for microinstructions. Horizontal microinstructions are wide words with each control signal assigned its own bit, allowing many operations to proceed simultaneously in one microinstruction cycle. This approach achieves maximum parallelism at the cost of large microinstruction words and therefore large control store sizes. Vertical microinstructions use encoded fields that represent groups of mutually exclusive control options; a small decoder translates each code into individual control signals. Vertical designs produce compact microcode at the expense of requiring a decode step and potentially limiting parallelism. Real designs often use a hybrid approach, with some fields horizontal and others encoded. A thorough treatment of both approaches and their tradeoffs appears in ScienceDirect's reference on microprogramming in computer organization.

Role in Modern Computer Architecture

With the rise of RISC architectures in the 1980s, direct hardwired control replaced microprogramming as the preferred technique for high-performance processors. RISC designs reduced the number of instruction formats and pipeline stages to the point where hardwired state machines could match or exceed the cycle time of microprogrammed units without the latency of control store access. However, microprogramming persists in complex instruction set computers: modern x86 processors translate complex CISC instructions into internal micro-operations (uops) at decode time, which are then issued to an out-of-order execution engine. In this sense, the x86 microarchitecture retains a form of microcode for instructions that cannot be decoded into a small fixed number of uops, as detailed in NITS Srinagar's academic notes on microprogrammed control units.

Applications

Microprogramming has applications in a range of computing contexts, including:

  • Firmware for complex instruction set processors requiring decode of variable-length instructions
  • Emulation layers that allow one processor to execute the instruction set of another
  • Fault-tolerant processor designs where microcode can be updated in the field to correct bugs
  • Educational computer architecture platforms where behavior is specified and modified in microcode
  • Digital signal processors and communications controllers with specialized instruction sets

Related Topics

Loading…